summaryrefslogtreecommitdiff
path: root/mate-panel/panel-toplevel.c
AgeCommit message (Collapse)AuthorFilesLines
2024-02-04Revert "Add "center-stick" capability applets on the panel"raveit651-2/+26
This reverts commit 38e00280e9d17282717595a05411736a308804c0.
2022-06-01Add "center-stick" capability applets on the panelThe Squash1-26/+2
Conventionally, the applets on a MATE Panel are positioned relative to the left edge of the panel (if the panel is horizontal) or the top edge (if the panel is vertical). There has also been some (buggy) support for positioning of applets relative to the right (or bottom) edge of the panel, so that applets on the right side of the panel will stay on the right side even if the user changes screen resolutions or if the panel changes size for some other reason. However, many users want to also place applets at or near the center of their panel(s). There is no such conventional support for positioning applets relative to the center of the panel, so users have positioned applets near the center of the panel -- but the position recorded is relative to the left side of the panel. As such, the applets will almost certainly shift over to the left or right slightly if the panel is ever resized, and the user will have to reposition all those centered applets yet again. This is especially frustrating if the user switches monitors on a regular basis! This patch radically revamps the MATE Panel's positioning framework, and deprecates the original "right-stick" feature. To replace the right-stick feature, this patch instead associates an "edge relativity" setting with each and every panel applet: An applet can be relative to the start (left/ top), end (right/bottom), or center of the panel. This setting can be changed using DConf/GSettings, using a custom panel layout file, or even by simply dragging the applet to the appropriate place on the panel. (Conventionally, applets are not even right-stuck automatically even when the user drags the applet over to the far right of the panel!) As a bonus, when the user drags an applet across the center of the panel, the applet will temporarily "stick" to the very center of the panel, to allow the user to very precisely align any applet they wish.
2022-03-23fix undefined reference to g_clear_signal_handler (glib < 2.62)rbuj1-2/+0
2022-01-26Fix implicit conversion changes signedness: 'gboolean' to 'guint'rbuj1-6/+6
2021-12-20Fix some -Wsign-compare warningsrbuj1-6/+10
2021-12-20Remove unnecessary cast in g_signal_connect* callrbuj1-5/+4
2021-12-19Upscale in panel_xutils_set_strutrbuj1-6/+1
2021-12-19panel-toplevel: fix the computed dimension for (non) auto hidden panelsrbuj1-1/+1
2021-12-19Use dashes instead of underscores in signal namesrbuj1-3/+3
2021-12-19Use GLib's new g_clear_signal_handler() function to simplify coderbuj1-14/+24
2021-12-16Use g_clear_pointer() and g_clear_object()rbuj1-25/+9
2021-12-11Use a blank line at mostrbuj1-2/+0
2021-06-22update copyright to 2021raveit651-0/+1
2021-01-07panel-toplevel: declaration of 'allocation' shadows a parameterrbuj1-4/+5
2021-01-06 Variable is reassigned a value before the old one has been usedrbuj1-2/+0
2020-09-07Remove variableScope warnings reported by cppcheckrbuj1-10/+12
cppcheck --enable=all . 2> err.txt grep variableScope err.txt
2020-08-07panel-toplevel: Fix -Wenum-conversion warningrbuj1-1/+1
2020-07-23panel-toplevel: Refactor panel_toplevel_update_hide_buttons_size()Tomas Bzatek1-18/+11
No real leak here except of the unnecessary gtk_css_provider_new() call, refactored for readability and to conform to the code style.
2020-07-05Avoid using single-line cpp commentsrbuj1-16/+16
2020-06-06panel-toplevel: Use monotonic time for measuring time intervalsrbuj1-41/+20
2020-06-06panel-toplevel: Use animation duration time instead of end timerbuj1-25/+13
2020-06-06panel-toplevel: Remove warning ‘GTimeVal’ is deprecatedrbuj1-49/+66
2020-01-14Avoid double a11y description on panel toplevelsColomban Wendling1-2/+2
Do not set an extra a11y name and description on an internal child of the panel, because its toplevel has most of it already through setting the GTK window title. Instead, explicitly set the a11y name and description on the toplevel directly, possibly overriding GTK's value implicitly set via gtk_window_set_title(), but which would be the same anyway. This prevents e.g. a screen reader vocalizing the panel name twice when entering it, once for the toplevel and once for the internal child. This also avoids announcing the panel again when moving from one of the hide buttons to one of the applets or launcher.
2019-08-16panel-toplevel: avoid deprecated 'gtk_css_provider_get_default'Pablo Barciela1-3/+4
2019-07-25panel-toplevel: fix applets placement on expanded vertical panelmonsta1-1/+5
fixes https://github.com/mate-desktop/mate-panel/issues/745
2019-07-25panel-toplevel: fix coding style and spacing a bitmonsta1-6/+3
2019-07-07Add Wayland backendWilliam Wold1-0/+20
2019-07-05Remove trailing whitespacesLaurent Napias1-4/+4
2019-06-24Use monitor size instead of screen size in panel-toplevel.cWilliam Wold1-47/+21
2019-06-23Wayland support for panel-toplevel.cWilliam Wold1-51/+98
2019-06-21Update to the new panel_multimonitor functionsWilliam Wold1-64/+34
2019-06-21Rename panel-multiscreen files panel-multimonitorWilliam Wold1-1/+1
2019-05-20fix random crashes on panel resetmonsta1-41/+43
- unref objects in toplevel's dispose function instead of finalize - disconnect from toplevel's GSettings objects before deleting them
2019-05-16[mate-panel] Avoid deprecated g_type_class_add_privateWu Xiaotian1-7/+3
2019-05-10panel-toplevel: Clarify calculation precedence for '&' and '?'Pablo Barciela1-3/+3
Fixes cppcheck warnings: [mate-panel/panel-toplevel.c:2315]: (style) Clarify calculation precedence for '&' and '?'. [mate-panel/panel-toplevel.c:4687]: (style) Clarify calculation precedence for '&' and '?'. [mate-panel/panel-toplevel.c:5036]: (style) Clarify calculation precedence for '&' and '?'.
2019-03-07GdkRectangle monitor -> monitor_geomWilliam Wold1-104/+104
2019-03-07Change panel_toplevel_get_monitor_geometry to fill in a GdkRectangle instead ↵William Wold1-165/+128
of 4 ints
2018-09-12panel-toplevel: fix memory leak in calculate_minimum_heightRui Caridade1-1/+2
Origin commit : https://github.com/GNOME/gnome-panel/commit/19129513e9dbfef9a985e0666d98d60a9e7b2779#diff-97cdffd8b53134e4fdfdd45b4a862042R2144
2018-06-29panel-toplevel: add position css classAlberts Muktupāvels1-14/+47
origin commit: https://gitlab.gnome.org/GNOME/gnome-panel/commit/6015418
2018-04-28limit size of panel-hide-buttonraveit651-6/+13
Thanks to Juha Leppänen, Kuopio, Finland for simplifing the code
2018-04-22Revert "panel-toplevel: Remove pointer boundary check in ↵raveit651-0/+1
panel_toplevel_queue_auto_hide()" This reverts commit 0d29acf6a70090ee771de2793b1af8e1388a430f. Which causes a regression. Fixes https://github.com/mate-desktop/mate-panel/issues/773
2018-03-19Fix hide buttons make panel biggerinfo-cppsp1-44/+79
fix #733
2018-02-24Scale monitor geometries down to device pixels to support multiple monitors ↵Victor Kareh1-13/+5
in HiDPI
2018-02-15Drawer cleanup and fix arrow behaviorinfo-cppsp1-4/+14
*Drawer coding style cleanup *Drawer code organized *Rearranged and labeled code *Drawer fix arrows *Fixed hide code for drawer in toplevel. *fix #528 *fix #704
2018-01-31require GTK+ 3.22 and GLib 2.50monsta1-125/+9
2018-01-25Support panel auto-scaling for HiDPI displaysVictor Kareh1-9/+32
*Fix scaling of panel widgets, buttons, and the menu bar *Draw grab handles at the ends of the panel *Fix size of _almost_ all included applets *Fix panel snapping coordinates *Down-scale monitor coordinates to support multi-monitors Author: Victor Kareh <[email protected]> Date: Wed Dec 20 14:03:18 2017 -0500
2017-12-17WidthOfScreen and HeightOfScreen implementationPablo Barciela1-7/+3
This commit reverts: https://github.com/mate-desktop/mate-panel/commit/7b2bc7d9f98c6ba8c2c31bdf9605faadb42a7e0e And it applies an alternative to fix the deprecated functions: gdk_screen_get_width gdk_screen_get_height
2017-11-29panel-toplevel: Remove pointer boundary check in ↵Björn Weber1-1/+0
panel_toplevel_queue_auto_hide()
2017-11-23Keep the right icons on bottom still displaying right when the resolution ↵张雯1-0/+28
change larger
2017-11-09panel-toplevel: remove duplicate break statementlukefromdc1-1/+0
found by cppcheck