Adding correct annotations to Gio.File.load_contents revealed that gjs
doesn't actually support array+length combinations. For 3.0 this would
be invasive to fix, so add a method to ShellGlobal which does what
we need.
https://bugzilla.gnome.org/show_bug.cgi?id=646333
If you have XFixes 5 (and corresponding xserver support) then we
add barriers on the panel and in the message tray corner so that
its easy to reach the corners even when there are monitors to the
sides of the primary monitor.
https://bugzilla.gnome.org/show_bug.cgi?id=622655
If the pointer moves on or off the stage while another process has a
grab, we will lose track of it. One example of this is that if you use
a popup menu from a message tray trayicon, the tray will stay up after
the menu goes away, because the shell never saw the pointer leave it.
Add a new method shell_global_sync_pointer() that causes clutter to
recheck what actor is under the pointer and generate leave/enter
events if appropriate.
Of course, we can't actually tell for sure when another process has a
grab, so we need a heuristic of when to call this. Currently we call
it from Chrome._windowsRestacked(), which is not really the right
thing at all, but does fix the menu-from-trayicon case...
https://bugzilla.gnome.org/show_bug.cgi?id=630842
Move the "system notification error" handling out of
util.js, and add it to ShellGlobal so we can start
calling it from across the codebase better (including
C).
https://bugzilla.gnome.org/show_bug.cgi?id=644402
This is another workaround for the lack of gjs supporting array
arguments, this time wrapping tp_connection_upgrade_contacts to
add new features to the connection's self contact.
https://bugzilla.gnome.org/show_bug.cgi?id=642793
Build gnome-shell as a binary linked against libmutter-wm, instead of
a module to be loaded by libmutter-wm. Move the majority of
initialization-type stuff from gnome_shell_plugin_start() into main().
We still build libgnome-shell as a shared library, so that the linker
doesn't discard all the methods that are never called from C.
https://bugzilla.gnome.org/show_bug.cgi?id=641724
Unfortunately the evolution-data-server client-side libraries seem to
block the calling thread. This is a major problem as we must never
ever block the main thread (doing so causes animations to flicker
etc.). In the worst case, this problem causes login to hang (without
falling back to fall-back mode) and in the best case it slows down
login until a network connection is acquired.
Additionally, in order to sanely use these evolution-data-server
libraries, GConf has to be involved and GConf is not thread-safe. So
it's not really feasible just moving the code to a separate
thread. Therefore, move all calendar IO out of process and use a
simple (and private) D-Bus interface for the shell to communicate with
the out-of-process helper.
For simplification, remove existing in-process code since internal
interfaces have been slightly revised. This means that the shell is no
longer using any native code for drawing the calendar dropdown.
https://bugzilla.gnome.org/show_bug.cgi?id=641396
Signed-off-by: David Zeuthen <davidz@redhat.com>
See commit f2158218bef0c51 in mutter. Basically, we need
to grab org.freedesktop.Notifications before anything else
in the session gets started.
Note: I intentionally removed the Util.killall bits. I believe that
for notification-daemon at least, if we specify
DBUS_NAME_FLAG_REPLACE_EXISTING, we'll take over the name. Not sure
about notify-osd; if that's still a problem, then what we need to do
is add killing (and possibly respawning) of notify-osd to
"gnome-shell --replace", and not have it embedded randomly in a JS file.
https://bugzilla.gnome.org/show_bug.cgi?id=642666
Using clutter_get_current_event_time can result into too old timestamps
when there is no current Clutter or Mutter event, since
clutter_get_current_event_time() returns the timestamp of the last event
delivered to Clutter. This can result in, for example, grabs failing. Use
the event time of the current event (if any) and CurrentTime otherwise.
https://bugzilla.gnome.org/show_bug.cgi?id=642188
Add the machinery to cancel the notification when a new playing a
new one (wrapping ca_context_cancel), then use it when scrolling
the status icon.
Not doing it for the slider because it causes noise, either with the
keyboard, with mouse drag or with mouse wheel.
https://bugzilla.gnome.org/show_bug.cgi?id=633667
The gnome-panel allows the user to hover over a tasklist entry
while draging to activate a minimized or obscured window and drop onto it.
Implement a similar behaviour by allowing draging to the activities button or
the hotcorner (and thus opening the overview), which allows the user to
activate any window (even on different workspaces) as a drop target.
https://bugzilla.gnome.org/show_bug.cgi?id=601731
The code to draw the root background has now been moved into Mutter,
with added smarts to not draw obscured portions. Remove the old
version of the code and clone the Mutter background actor to draw
the background in the overview.
https://bugzilla.gnome.org/show_bug.cgi?id=634836
MutterWindow and MutterPlugin have been renamed to MetaWindowActor
and MetaPlugin, mutter_plugin_list_windows() to
meta_plugin_list_window_actors(). Adapt to those changes.
https://bugzilla.gnome.org/show_bug.cgi?id=632500
Gjs changed to separate the "basic" API from "embedder" API. Unfortunately
due to our use of the importer API and a few other bits, we need to use
the "module" one. In the future I plan to extend the core API to
support this use case.
Add volume control indicator which uses API from gnome-volume-control
to interact with PulseAudio and shows both input and output volumes.
Also adds a small wrapper around libcanberra in ShellGlobal, used by the
volume indicator to provide auditive feedback.
https://bugzilla.gnome.org/show_bug.cgi?id=629455
* Use --warn-all, --warn-error
* Fix various broken gtk-doc
* Drop unused shell_get_event_related
* For header defines, we currently require them to end in _H to be skipped
* Drop the no-longer-necessary fix-meta-rectangle.py hack
* Move to the convention of using -private.h for headers that are,
well, private.
* Add shell-wm-private.h
Add SHELL_STAGE_INPUT_MODE_FOCUSED, to move the keyboard focus to the
shell without grabbing the keyboard or mouse, and make
stage_input_mode into a GObject property so that (among other things),
callers can tell when MODE_FOCUSED reverts back to MODE_NORMAL.
https://bugzilla.gnome.org/show_bug.cgi?id=623429
The conversion of GdkRectangle to a typedef for cairo_rectangle_int_t
in GTK+-3 makes it no longer a proper boxed type (it's still registered
boxed, but gobject-introspection doesn't know that.) So, switch to using
MetaRectangle, which is now registered as a boxed type by Mutter.
https://bugzilla.gnome.org/show_bug.cgi?id=621845
Use GSettings for all Shell configuration. GConf is kept to read
configuration from external programs (Metacity, Nautilus and Magnifier),
but ShellGConf is removed because it's mostly useless for the few calls
we still have. Also get rid of unused GConf code in ShellAppSystem.
A basic GConf schema is still used to override Metacity defaults and
configure Magnifier in a system-wide fashion. GConf is also used as
GSettings backend via the GSETTINGS_BACKEND environment variable.
All of this will be removed when these programs have been ported
to GSettings and able to use dconf.
GLib 2.25.9 is required. Schemas are converted to the new XML format,
and compiled at build time in data/ so that the Shell can be run from
the source tree. This also requires setting the GSETTINGS_SCHEMA_DIR
environment variable both when running installed or from source tree,
in src/gnome-shell.in and src/gnome-shell-clock-preferences.in.
https://bugzilla.gnome.org/show_bug.cgi?id=617917
Currently we only relayout when the screen size changes, this gets
the cases where a monitor gets added/removed but not when the primary
monitor changes.
We need to relayout on all monitor layout changes.
Remove ShellGlobal::screen-size-changed signal as it is no longer used, Gdk is
used to track changes now.
A ShellGlobal::gdk-screen property is added for this purpose.
https://bugzilla.gnome.org/show_bug.cgi?id=620377
Add a helper function to write a string as UTF-8 to a GOutputStream.
The signature of GOutputStream:
gboolean g_output_stream_write_all (GOutputStream *stream,
const void *buffer,
gsize count,
gsize *bytes_written,
GCancellable *cancellable,
GError **error);
Can't currently be handled by GJS.
https://bugzilla.gnome.org/show_bug.cgi?id=618189
To support scheduling performance-measurement scripts that want to run
a number of actions in series, add shell_global_run_at_leisure() to run
a callback when all work is finished.
The initial implementation of this is not that accurate: we track
business in Tweener.js via new shell_global_begin_work(),
shell_global_end_work() functions, and we also handle the case
where the main loop is continually busy.
https://bugzilla.gnome.org/show_bug.cgi?id=618189
The ShellGlobal initialization performs several actions like connecting
to the X server, ensuring directories exist, etc., that are problematic
because we were creating the object even when running the binary for
introspection scanning. During compilation we may not even have X11
available in e.g. autobuilder type environments, and it's just a
bad idea to connect even if we do.
Avoid this by deferring creation of the ShellGlobal object
until the plugin is actually started.
Now that we're initializing things later, remove the connection to
screen changes, and initialize cached ShellGlobal state at the point
when the plugin is set. The root pixmap actor is now sized initially
on creation too. Instead of relying on screen-size-changed being
emitted on startup, explicitly invoke _relayout().
https://bugzilla.gnome.org/show_bug.cgi?id=618371
Starting with gtk-2.20.0 there is a gdk_screen_get_primary_monitor,
which supports querying the primary monitor from xrandr.
But due to a sorting bug and lack of heuristics in the fallback path,
it isn't really useable.
Those bugs are fixed in gtk-2.20.1, so use it when building with
gtk-2.20.1+.
https://bugzilla.gnome.org/show_bug.cgi?id=608647
Adds the ability to create one or more zoom regions that show magnified or
enhanced views of the desktop. The magnifier provides options for:
* magnification factor,
* four mouse tracking modes common to screen magnifiers,
* positioning the magnified view in one of four screen location, or full screen,
* crosshairs to accentuate the position of the mouse,
* user preferences persistence via GConf (schemas in
.../data/gnome-shell.schemas).
* a DBus API to allow other processes to drive the magnifier as a service.
https://bugzilla.gnome.org/show_bug.cgi?id=595507
When creating the directory to store user data, XDG_DATA_HOME is
not guaranteed to exist. Also, the standard mandates permissions
of 0700 for the directory.
https://bugzilla.gnome.org/show_bug.cgi?id=617555
While the extension system already uses an XDG location (XDG_CONFIG_HOME),
other components use the deprecated $HOME/.gnome2 directory.
Replace both with XDG_DATA_HOME - the existing data (app usage stats,
looking glass history and extensions) is not migrated to the new location.
https://bugzilla.gnome.org/show_bug.cgi?id=617555
We can't use gdk_display_get_pointer/gdk_window_get_pointer from gjs
when XKB is active. We already had a wrapper that did the
get-modifier-state part of that, but some places also need the
get-pointer-location part of it. So update our wrapper to return both,
and update js code to use it.
https://bugzilla.gnome.org/show_bug.cgi?id=613428
Currently shell_global_get_primary_monitor just returns the first screen,
in the list as primary.
This is not always correct as the first screen reported by mutter isn't always,
the first one listed by RANDR.
Use gdk_screen_* to query the monitor information and add a heuristic to prefer
LVDS displays (similar like in done for gnome-panel) to prefer the laptop's
internal screen over external displays.
https://bugzilla.gnome.org/show_bug.cgi?id=608647