Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Switch to GitLab Next
Sign in / Register
Toggle navigation
tint2
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Insights
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
Issues
45
Issues
45
List
Boards
Labels
Service Desk
Milestones
Merge Requests
3
Merge Requests
3
Security & Compliance
Security & Compliance
Dependency List
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
o9000
tint2
Commits
ceb6a442
Commit
ceb6a442
authored
Sep 01, 2017
by
o9000
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Launcher: fix layout on vertical panels
parent
6a1b2f06
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
0 deletions
+14
-0
src/launcher/launcher.c
src/launcher/launcher.c
+14
-0
No files found.
src/launcher/launcher.c
View file @
ceb6a442
...
...
@@ -64,6 +64,8 @@ void launcher_reload_hidden_icons(Launcher *launcher);
void
launcher_icon_on_change_layout
(
void
*
obj
);
int
launcher_compute_desired_size
(
void
*
obj
);
void
relayout_launcher
();
void
default_launcher
()
{
launcher_enabled
=
0
;
...
...
@@ -95,6 +97,7 @@ void init_launcher_panel(void *p)
launcher
->
area
.
_draw_foreground
=
NULL
;
launcher
->
area
.
size_mode
=
LAYOUT_FIXED
;
launcher
->
area
.
_resize
=
resize_launcher
;
launcher
->
area
.
_on_change_layout
=
relayout_launcher
;
launcher
->
area
.
_compute_desired_size
=
launcher_compute_desired_size
;
launcher
->
area
.
resize_needed
=
1
;
schedule_redraw
(
&
launcher
->
area
);
...
...
@@ -325,6 +328,17 @@ gboolean resize_launcher(void *obj)
return
TRUE
;
}
void
relayout_launcher
(
void
*
obj
)
{
Launcher
*
launcher
=
(
Launcher
*
)
obj
;
for
(
GSList
*
l
=
launcher
->
list_icons
;
l
;
l
=
l
->
next
)
{
LauncherIcon
*
launcherIcon
=
(
LauncherIcon
*
)
l
->
data
;
if
(
!
launcherIcon
->
area
.
on_screen
)
continue
;
launcher_icon_on_change_layout
(
launcherIcon
);
}
}
// Here we override the default layout of the icons; normally Area layouts its children
// in a stack; we need to layout them in a kind of table
void
launcher_icon_on_change_layout
(
void
*
obj
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment