Commit graph

198 commits

Author SHA1 Message Date
Mohammed Sadiq
2893f8e3f9 color: Select first device row only if non-NULL
Otherwise we might read some invalid memory resulting in a crash
2022-11-15 16:45:00 +05:30
Jake Dane
89443fe550 desktop: Remove obsolete Bugzilla entries
The `X-GNOME-Bugzilla-*` entries were for use by bug-buddy, a GNOME 2
technology that's been gone for over a decade. These entries are
obsolete and can be removed from all desktop files.

The `X-GNOME-Settings-Panel` entry is also obsolete as far as I can
tell and only these panels had it in their desktop file: notifications,
sharing, sound and user-accounts. These entries can also be removed.

After removing the `X-GNOME-Bugzilla-*` entries, the desktop files have
no more variables in them. The meson `configure_file` step is therefor
pointless—there are no variables to configure. As such the
`*.desktop.in.in` files are renamed to `*.desktop.in` to reflect this
and `meson.build` files are modified to remove `configure_file` step.
2022-10-20 13:20:09 +00:00
Robert Ancell
2536f946eb color: Remove dead code
This code was disabled as part of the GTK4 port (d00cc39)
2022-06-17 01:42:12 +00:00
Christopher Davis
200e524aab color: Don't update toolbar buttons when the toolbar is in destruction
GtkListBox's dispose function removes all rows, and
`gtk_list_box_remove ()` sends `row-selected`. In turn,
as we listen to row-selected, we end up calling
functions on our toolbar while it may be in the
process of disposing. This causes a crash.

This commit introduces an early return if the toolbar is
being destroyed.
2022-02-01 14:06:18 +00:00
Jakub Steiner
13376ecb8b Add individual app icons 2022-01-31 14:08:22 +00:00
Georges Basile Stavracas Neto
0ab20af9ba panels: Switch to CcPanel content
Start porting panels to the new panel format. This commit
temporarily makes panels have two titlebar, which will be
fixed soon.
2022-01-20 02:23:42 +00:00
Jan Beich
37b29c32cb meson: drop unused argument for i18n.merge_file()
Ignored in Meson < 0.60.0, deprecated since 0.60.1 and fatal since 0.61.0.

panels/applications/meson.build:10:5: ERROR: Function does not take positional arguments.
panels/background/meson.build:10:5: ERROR: Function does not take positional arguments.
panels/camera/meson.build:10:5: ERROR: Function does not take positional arguments.
[...]
2022-01-07 17:22:43 +00:00
Christopher Davis
981a8cea7b panels: Use .boxed-list instead of .content
The `.content` style class is deprecated in favor
of the `.boxed-list` style class, which is named
after the design pattern it's used for.
2021-12-16 12:52:44 -08:00
Georges Basile Stavracas Neto
d00cc3929e [WIP] color: Port to GTK4
This is very rough still. The calibration code
is entirely untested.
2021-12-14 22:34:21 -03:00
Bastien Nocera
a9c398e5d9 color: Remove profile upload feature
As it was already removed in colord itself:
98f83acc91 (diff-cb19db05cc548372b27ebee7d47bc00b6788ad05da6f5d7fff107c45bbfba38f)

This removes the only direct libsoup 2.x dependency in
gnome-control-center.
2021-11-18 16:39:44 +01:00
Robert Ancell
ed41626c67 color: Search path for gcm-viewer/gcm-calibrate rather than rely on exact location 2020-12-13 21:45:56 +00:00
Benjamin Berg
dd2ecbfa9d color: Fix order of arguments to gcm_prefs_device_changed_cb
Commit f1893b8e8 (color: Connect signals with g_signal_connect_object
in swapped form) changed the connect call to use G_CONNECT_SWAPPED, but
it did not change the order of the arguments for the
gcm_prefs_device_changed_cb function.

Fixes: #1082
2020-08-18 21:00:36 +00:00
Yuri Chornoivan
e7050ab6f4 Fix minor typos 2020-07-20 10:38:09 +03:00
Adrien Plazas
f06379e30c Replace HdyColumn by HdyClamp
In libhandy 1, HdyClamp replaces HdyColumn. This stops setting values
when they match HdyClamp's defaults.
2020-07-20 08:04:28 +02:00
Robert Ancell
f1893b8e8b color: Connect signals with g_signal_connect_object in swapped form 2020-03-30 16:18:49 +13:00
Robert Ancell
93b14a4339 panel: Move shared GCancellable code into panel class
Make the panel class provide a cancellable that will be cancelled when the panel
is destroyed. Panel implementations can use this and not have to mangage the
cancellable themselves. Consolidate cases where panels had multiple cancellables
that were all being used for this behaviour.
2020-02-03 09:36:24 +13:00
Robert Ancell
871f10bcf4 color: Make .ui filename match the .c filename 2019-09-09 21:58:00 +00:00
Robert Ancell
97985a664e Remove unused GNOMELOCALEDIR defines 2019-09-09 21:45:53 +00:00
Robert Ancell
8ecdd32971 color: Fix compile warning on g_clear_pointer 2019-02-07 11:22:11 +13:00
Adrien Plazas
b4520d07b5 color: Make the row labels ellipsizable
This better allows to better handle a narrow window.
2019-01-29 10:35:18 +00:00
Adrien Plazas
eaeb64d85e color: Use a HdyColumn
This helps the panel to fit in narrower windows.
2019-01-29 10:35:18 +00:00
Robert Ancell
3695c22ab5 datetime: Make .ui filename match the .c filename 2018-11-12 16:41:01 +00:00
Philip Withnall
c07b357311 panels: Add X-GNOME-UsesNotifications to several desktop files
gnome-settings-daemon emits notifications related to these four control
panels. If we add X-GNOME-UsesNotifications to their desktop files, the
user will be able to control the notifications.

https://wiki.gnome.org/Initiatives/GnomeGoals/NotificationSource

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2018-11-01 17:22:21 +00:00
Kalev Lember
edc52c170d color: Fix fallout from the GtkTemplate port
Correct a typoed variable name so that calibration works again, instead
of crashing.

GLib-GObject-WARNING **: 15:52:50.561: invalid cast from 'GtkBox' to 'GtkEntry'
2018-09-15 17:30:44 +02:00
Georges Basile Stavracas Neto
7d58972623 Revert "color: Cache D-Bus proxies"
This reverts commit 8e56ea35f3.
2018-08-27 12:56:20 +00:00
Sam Hewitt
24174173be common: update pixel_size values to base 16 for icon clarity 2018-07-10 17:52:08 -04:00
Robert Ancell
a64ef75ad7 Simplify use of GCancellable
g_cancellable_cancell can be called without checking for a NULL value.
Use g_clear_object instead of g_object_unref
2018-06-01 21:03:19 +00:00
Robert Ancell
5ea7632b83 color: Use GtkTemplate 2018-05-30 16:27:46 +12:00
Robert Ancell
490bee5a23 color: Use g_auto for variables 2018-05-30 15:46:01 +12:00
Robert Ancell
04e36953ff color: Replace ifdefs with #pragma once 2018-05-30 15:09:55 +12:00
Robert Ancell
770a3b1df6 color: Replace GObject boilerplace with G_DECLARE_TYPE 2018-05-30 15:08:44 +12:00
Benjamin Berg
c2f601a9d4 Move common panel code from shell/ to panel/common
This creates a new static library called libwidget which the shell links
against.
2018-04-17 15:26:59 +02:00
Georges Basile Stavracas Neto
8e56ea35f3 color: Cache D-Bus proxies 2018-04-06 22:23:38 -03:00
Georges Basile Stavracas Neto
9e8a4729f0 color: Remove deprecated functions and silence compiler warnings
The color calibration code called on GdkScreen API, an API that is
now mostly deprecated in favour of GdkDisplay and GdkMonitor.

This commit updates that, and also removes a compiler warning about
different enum types.
2018-03-07 11:08:43 -03:00
Piotr Drąg
7265bd53a0 Add translator comments to .desktop files
Icons are confusing translators, and gettext
is unlikely to get fixed any time soon.
2018-02-23 18:49:35 +01:00
Iñigo Martínez
0dd386f405 build: Migrate from Intltool to Gettext
Recent versions of Gettext are able to translate several formats
that are used in GNOME applications. This patch migrates from
Intltool to Gettext by using meson's i18n features.

https://bugzilla.gnome.org/show_bug.cgi?id=787588
2018-01-23 10:49:31 +01:00
Georges Basile Stavracas Neto
32613ed4f3 color: Replace deprecated functions
soup_session_sync_new_with_options → soup_session_new_with_options
gtk_show_uri → gtk_show_uri_on_window
2018-01-21 11:12:06 -02:00
Iñigo Martínez
dc0988d47c build: Remove autotools
To avoid the burden of maintaining multiple build systems, this
patch removes autotools support.

https://bugzilla.gnome.org/show_bug.cgi?id=785414
2018-01-18 12:20:08 +01:00
Piotr Drąg
b65e31323a panels: Remove soft hyphens from .desktop files
With the old shell gone, there is no need to work around cut off panel
names (bug #647087). As it stands now, it only confuses translators
(invisible characters are hard to, well, see).

https://bugzilla.gnome.org/show_bug.cgi?id=792629
2018-01-18 00:12:04 -02:00
Iñigo Martínez
32edd6789e build: Port to meson build system
Meson is a build system focused on speed an ease of use, which
helps speeding up the software development. This patch adds meson
support along autotools.

https://bugzilla.gnome.org/show_bug.cgi?id=785414
2018-01-17 20:09:35 -02:00
Sebastien Bacher
12ddb730d6 color: set min-content-height on the profiles list
otherwise there is only space for one line to be displayed
https://bugzilla.gnome.org/show_bug.cgi?id=787931
2017-09-20 10:29:37 -03:00
Allan Day
87568e9250 Harmonize list box row layouts
While it isn't possible, or even advisable, to make all the list
box rows the same height, using a number of standard heights will
make the control center feel more harmoneous.

Adust the height of the list box rows in Color, Date & Time,
Mouse & Touchpad, Network, Privacy, Region & Language, Sharing
and Universal Access. Makes standard rows that contain labels
and/or controls 58px tall. Some other rows, such as those which
contain two lines of text, are allowed to be taller.

https://bugzilla.gnome.org/show_bug.cgi?id=786384
2017-08-20 18:38:48 +02:00
Allan Day
8a8e53ab8a Standardize vertical spacing of panels
Ensure that the vertical spacing inside each panel is similar.
This makes the transition between each panel smoother and makes
the control center feel more cohesive.

Settings panels are given 32px above and below their content
and 32px vertical space between major sections. 12px space is
placed below headings.

Bluetooth, displays and printers are not addressed.

https://bugzilla.gnome.org/show_bug.cgi?id=786384
2017-08-20 18:38:42 +02:00
Georges Basile Stavracas Neto
024bb97a12 color: Avoid casting before checking for errors
When the asynchronous operation is finished in the Color
panel, the user may potentially have already changed to
another panel, making the CcColorPanel reference invalid.

In the callback, the first thing that is done is casting
(and type-checking) the CcColorPanel pointer, causing
a segmentation fault.

Fix that by only casting anything after checking the result
of the asynchronous call.

https://bugzilla.gnome.org/show_bug.cgi?id=786096
2017-08-16 18:07:19 -03:00
Georges Basile Stavracas Neto
f7bdd3c969 panels: Minor adjustments for the new shell 2017-08-09 19:31:41 +02:00
Bastien Nocera
3f0510cac8 build: Better libm checks
Use AC_CHECK_LIBM instead of AC_CHECK_LIB(m,...
and use $(LIBM) instead of hardcoding "-lm" in Makefiles.
2017-02-08 19:21:53 +01:00
Piotr Drąg
ce23ff67be color: use Unicode in translatable strings
See https://developer.gnome.org/hig/stable/typography.html

https://bugzilla.gnome.org/show_bug.cgi?id=772199
2016-10-03 15:20:36 +02:00
Bastien Nocera
c7a5451474 color: Use title caps for "Add profile" dialogue title
https://bugzilla.gnome.org/show_bug.cgi?id=763467
2016-10-03 14:53:48 +02:00
Georges Basile Stavracas Neto
2777fd583d panels: use the new categories
Following the previous patch, this patch adds the new alternative
categories to the panels' Desktop files. These alternative categories
are only relevant for the alternative Shell, and do not break the
current Shell in any way.

https://bugzilla.gnome.org/show_bug.cgi?id=767301
2016-06-14 12:16:43 -03:00
Bastien Nocera
5c10ce45b8 panels: Fix translators comments being truncated
Commit b3be076 added soft hyphens along with a comment for translators
to use those soft hyphens. Except that gettext would only grab the one
line out of the four we wrote for translators to read. Put them all on
the same line so that gettext actually extracts those.

https://bugzilla.gnome.org/show_bug.cgi?id=765778
2016-04-28 23:38:00 +02:00