Top |
ClutterActor * | background-actor | Read |
ClutterActor * | bottom-window-group | Read |
char * | datadir | Read |
ClutterActor * | desklet-container | Read |
MetaDisplay * | display | Read |
StFocusManager * | focus-manager | Read |
GdkScreen * | gdk-screen | Read |
char * | imagedir | Read |
ClutterActor * | overlay-group | Read |
CinnamonScreen * | screen | Read |
int | screen-height | Read |
int | screen-width | Read |
gboolean | session-running | Read / Write / Construct Only |
GSettings * | settings | Read |
ClutterActor * | stage | Read |
CinnamonStageInputMode | stage-input-mode | Read / Write |
ClutterActor * | top-window-group | Read |
guint | ui-scale | Read |
char * | userdatadir | Read |
ClutterActor * | window-group | Read |
CinnamonWM * | window-manager | Read |
MetaWorkspaceManager * | workspace-manager | Read |
CinnamonGlobal *
cinnamon_global_get (void
);
Gets the singleton global object that represents the desktop.
GdkScreen *
cinnamon_global_get_gdk_screen (CinnamonGlobal *global
);
GList *
cinnamon_global_get_window_actors (CinnamonGlobal *global
);
Gets the list of MetaWindowActor for the plugin's screen
GSettings *
cinnamon_global_get_settings (CinnamonGlobal *global
);
Get the global GSettings instance.
guint32
cinnamon_global_get_current_time (CinnamonGlobal *global
);
gchar * cinnamon_global_get_md5_for_string (CinnamonGlobal *global
,const gchar *string
);
void
cinnamon_global_dump_gjs_stack (CinnamonGlobal *global
);
Prints out the gjs stack
gboolean cinnamon_global_begin_modal (CinnamonGlobal *global
,guint32 timestamp
,MetaModalOptions options
);
Grabs the keyboard and mouse to the stage window. The stage will
receive all keyboard and mouse events until cinnamon_global_end_modal()
is called. This is used to implement "modes" for the shell, such as the
overview mode or the "looking glass" debug overlay, that block
application and normal key shortcuts.
TRUE
if we succesfully entered the mode. FALSE
if we couldn't
enter the mode. Failure may occur because an application has the pointer
or keyboard grabbed, because Mutter is in a mode itself like moving a
window or alt-Tab window selection, or because cinnamon_global_begin_modal()
was previouly called.
void cinnamon_global_end_modal (CinnamonGlobal *global
,guint32 timestamp
);
Undoes the effect of cinnamon_global_begin_modal()
.
void cinnamon_global_set_stage_input_mode (CinnamonGlobal *global
,CinnamonStageInputMode mode
);
Sets the input mode of the stage; when mode
is
CINNAMON_STAGE_INPUT_MODE_NONREACTIVE
, then the stage does not absorb
any clicks, but just passes them through to underlying windows.
When it is CINNAMON_STAGE_INPUT_MODE_NORMAL
, then the stage accepts
clicks in the region defined by
cinnamon_global_set_stage_input_region()
but passes through clicks
outside that region. When it is CINNAMON_STAGE_INPUT_MODE_FULLSCREEN
,
the stage absorbs all input.
When the input mode is CINNAMON_STAGE_INPUT_MODE_FOCUSED
, the pointer
is handled as with CINNAMON_STAGE_INPUT_MODE_NORMAL
, but additionally
the stage window has the keyboard focus. If the stage loses the
focus (eg, because the user clicked into a window) the input mode
will revert to CINNAMON_STAGE_INPUT_MODE_NORMAL
.
Note that whenever a muffin-internal Gtk widget has a pointer grab,
Cinnamon behaves as though it was in
CINNAMON_STAGE_INPUT_MODE_NONREACTIVE
, to ensure that the widget gets
any clicks it is expecting.
void cinnamon_global_set_stage_input_region (CinnamonGlobal *global
,GSList *rectangles
);
Sets the area of the stage that is responsive to mouse clicks when
the stage mode is CINNAMON_STAGE_INPUT_MODE_NORMAL
(but does not change the
current stage mode).
global |
the CinnamonGlobal |
|
rectangles |
a list of MetaRectangle describing the input region. |
[element-type Meta.Rectangle] |
void cinnamon_global_set_cursor (CinnamonGlobal *global
,CinnamonCursor type
);
Set the cursor on the stage window.
void
cinnamon_global_unset_cursor (CinnamonGlobal *global
);
Unset the cursor on the stage window.
guint32 cinnamon_global_create_pointer_barrier (CinnamonGlobal *global
,int x1
,int y1
,int x2
,int y2
,int directions
);
void cinnamon_global_destroy_pointer_barrier (CinnamonGlobal *global
,guint32 barrier
);
void cinnamon_global_get_pointer (CinnamonGlobal *global
,int *x
,int *y
,ClutterModifierType *mods
);
Gets the pointer coordinates and current modifier key state.
This is a wrapper around gdk_display_get_pointer()
that strips
out any un-declared modifier flags, to make gjs happy; see
https://bugzilla.gnome.org/show_bug.cgi?id=597292.
global |
the CinnamonGlobal |
|
x |
the X coordinate of the pointer, in global coordinates. |
[out] |
y |
the Y coordinate of the pointer, in global coordinates. |
[out] |
mods |
the current set of modifier keys that are pressed down. |
[out] |
void cinnamon_global_set_pointer (CinnamonGlobal *global
,int x
,int y
);
Sets the pointer coordinates.
This is a wrapper around gdk_device_warp()
.
global |
the CinnamonGlobal |
|
x |
the X coordinate of the pointer, in global coordinates. |
[in] |
y |
the Y coordinate of the pointer, in global coordinates. |
[in] |
void
cinnamon_global_begin_work (CinnamonGlobal *global
);
Marks that we are currently doing work. This is used to to track
whether we are busy for the purposes of cinnamon_global_run_at_leisure()
.
A count is kept and cinnamon_global_end_work()
must be called exactly
as many times as cinnamon_global_begin_work()
.
void
cinnamon_global_end_work (CinnamonGlobal *global
);
Marks the end of work that we started with cinnamon_global_begin_work()
.
If no other work is ongoing and functions have been added with
cinnamon_global_run_at_leisure()
, they will be run at the next
opportunity.
void cinnamon_global_run_at_leisure (CinnamonGlobal *global
,CinnamonLeisureFunction func
,gpointer user_data
,GDestroyNotify notify
);
Schedules a function to be called the next time Cinnamon is idle. Idle means here no animations, no redrawing, and no ongoing background work. Since there is currently no way to hook into the Clutter master clock and know when is running, the implementation here is somewhat approximation. Animations done through Cinnamon's Tweener module will be handled properly, but other animations may be detected as terminating early if they can be drawn fast enough so that the event loop goes idle between frames.
The intent of this function is for performance measurement runs where a number of actions should be run serially and each action is timed individually. Using this function for other purposes will interfere with the ability to use it for performance measurement so should be avoided.
global |
the CinnamonGlobal |
|
func |
function to call at leisure |
|
user_data |
data to pass to |
|
notify |
function to call to free |
void
cinnamon_global_sync_pointer (CinnamonGlobal *global
);
Ensures that clutter is aware of the current pointer position, causing enter and leave events to be emitted if the pointer moved behind our back (ie, during a pointer grab).
GAppLaunchContext *
cinnamon_global_create_app_launch_context
(CinnamonGlobal *global
);
Create a GAppLaunchContext set up with the correct timestamp, and targeted to activate on the current workspace.
void cinnamon_global_notify_error (CinnamonGlobal *global
,const char *msg
,const char *details
);
Show a system error notification. Use this function when a user-initiated action results in a non-fatal problem from causes that may not be under system control. For example, an application crash.
void
cinnamon_global_real_restart (CinnamonGlobal *global
);
Restart the current process.
void
cinnamon_global_reexec_self (CinnamonGlobal *global
);
Initiates the shutdown sequence.
void
cinnamon_global_segfault (CinnamonGlobal *global
);
Crashes Cinnamon by causing a segfault
void cinnamon_global_alloc_leak (CinnamonGlobal *global
,gint mb
);
Request mb megabytes allocated. This is just for debugging.
“background-actor”
property “background-actor” ClutterActor *
Actor drawing root window background.
Owner: CinnamonGlobal
Flags: Read
“bottom-window-group”
property “bottom-window-group” ClutterActor *
Actor holding window actors that must appear below desklets.
Owner: CinnamonGlobal
Flags: Read
“datadir”
property “datadir” char *
Directory containing Cinnamon data files.
Owner: CinnamonGlobal
Flags: Read
Default value: NULL
“desklet-container”
property “desklet-container” ClutterActor *
Actor that will hold desklets.
Owner: CinnamonGlobal
Flags: Read
“display”
property “display” MetaDisplay *
Metacity display object for Cinnamon.
Owner: CinnamonGlobal
Flags: Read
“focus-manager”
property “focus-manager” StFocusManager *
Cinnamon's StFocusManager.
Owner: CinnamonGlobal
Flags: Read
“gdk-screen”
property “gdk-screen” GdkScreen *
Gdk screen object for Cinnamon.
Owner: CinnamonGlobal
Flags: Read
“imagedir”
property “imagedir” char *
Directory containing Cinnamon image files.
Owner: CinnamonGlobal
Flags: Read
Default value: NULL
“overlay-group”
property “overlay-group” ClutterActor *
Actor holding objects that appear above the desktop contents.
Owner: CinnamonGlobal
Flags: Read
“screen”
property “screen” CinnamonScreen *
Cinnamon screen object.
Owner: CinnamonGlobal
Flags: Read
“screen-height”
property “screen-height” int
Screen height, in pixels.
Owner: CinnamonGlobal
Flags: Read
Allowed values: >= 0
Default value: 1
“screen-width”
property “screen-width” int
Screen width, in pixels.
Owner: CinnamonGlobal
Flags: Read
Allowed values: >= 0
Default value: 1
“session-running”
property “session-running” gboolean
If the session startup has already finished.
Owner: CinnamonGlobal
Flags: Read / Write / Construct Only
Default value: FALSE
“settings”
property “settings” GSettings *
GSettings instance for Cinnamon configuration.
Owner: CinnamonGlobal
Flags: Read
“stage”
property “stage” ClutterActor *
Stage holding the desktop scene graph.
Owner: CinnamonGlobal
Flags: Read
“stage-input-mode”
property“stage-input-mode” CinnamonStageInputMode
The stage input mode.
Owner: CinnamonGlobal
Flags: Read / Write
Default value: CINNAMON_STAGE_INPUT_MODE_NORMAL
“top-window-group”
property “top-window-group” ClutterActor *
Actor holding popup menus and other actors which must appear on top of the panels.
Owner: CinnamonGlobal
Flags: Read
“ui-scale”
property “ui-scale” guint
Current UI Scale.
Owner: CinnamonGlobal
Flags: Read
Default value: 1
“userdatadir”
property “userdatadir” char *
Directory containing Cinnamon user data.
Owner: CinnamonGlobal
Flags: Read
Default value: NULL
“window-group”
property “window-group” ClutterActor *
Actor holding window actors.
Owner: CinnamonGlobal
Flags: Read
“window-manager”
property“window-manager” CinnamonWM *
Window management interface.
Owner: CinnamonGlobal
Flags: Read
“notify-error”
signalvoid user_function (CinnamonGlobal *cinnamonglobal, char *arg1, char *arg2, gpointer user_data)
Flags: Run Last
“scale-changed”
signalvoid user_function (CinnamonGlobal *cinnamonglobal, gpointer user_data)
Flags: Run Last
“shutdown”
signalvoid user_function (CinnamonGlobal *cinnamonglobal, gpointer user_data)
Flags: Run Last