I want to write a Gnome-Shell extension that can tell how long a session has not received any user input. I know that calling XScreenSaverQueryInfo will give me that information, but I can't find a way to call it from my gjs extension. What do I need to do to get this to work?
Using C libraries from a Gnome-Shell extension
753 Views Asked by Dan At
1
There are 1 best solutions below
Related Questions in JAVASCRIPT
- Angular Show All When No Filter Is Supplied
- Why does a function show up as not defined
- I count the time the user takes to solve my quiz using Javascript but I want the same time displayed on another page
- Set "More" "Less" font size
- Using pagination on a table in AngularJS
- How to sort these using Javascript or Jquery Most effectively
- how to fill out the table with next values in array with one button
- State with different subviews
- Ajax jQuery firing multiple time display event for the same result
- Getting and passing MVC Model data to AngularJS controller
- Disable variable in eval
- javascript nested loops waiting for user input
- .hover() seems to overwrite .click()
- How to sort a multi-dimensional array by the second array in descending order?
- How do I find the fonts that are not loading in a CORS situation ( MoovWeb )?
Related Questions in GNOME
- Guest CentOS in virtualbox failed to load GNOME Power manager
- how I can get return code of org.gnome.SessionManager.CanShutsown in JS?
- Connecting to Bluetooth Device using bluetooth_client_connect_service() - gnome-bluetooth 3.8.2.1
- Methods to install custom style properties in GTK+-widgets
- Suppressing GTK errors in Valgrind
- GLib-GIO-Message: Using the 'memory' GSettings backend. Happened in Ubuntu 16.10 after going from GNOME to Unity to GNOME again
- Get attributes of GnomeKeyring key with Python 2.7 GTK3 on Ubuntu 14.04
- Remove alpha ClutterActor
- Vim in terminal is slow
- how to remove the -j9 option from the build process in gnome-builder
- Can GNOME Shell extensions move the pointer? If so, how?
- Todoist Integration with gnome-todo
- destroying a class instance doesn't kill instances it owns in vala
- For-Loop Segmentation -- Excessive run ( i < SIZE, but i = SIZE)
- How to change shortcut for switching between work-space in fedora 20?
Related Questions in GNOME-SHELL
- Can GNOME Shell extensions move the pointer? If so, how?
- How to set a PNG file in a Gnome Shell extension for St.Icon
- How to change windows order in gnome?
- x11 gnome-shell display freezes every minute for 25 seconds
- Gnome Shell - Do not let windows float to first or accross workspaces
- How to access environement variable inside a Gnome-Shell extension
- Gnome 3 extensions resources
- How to add arguments to links in gnome-shell menu
- css on the gnome-shell that make a beveled button
- How to deiconify and raise Tk window when using GNOME as desktop environment
- gnome-shell span_command_line_sync command is giving numerical values instead of text
- How to maintain a gnome-extension collaboratively?
- App icon from deb package not showing on Gnome
- How to apply gsetting timeout settings only for a specific gnome shell rather than in the entire system?
- Gnome-shell extension. Working with windows
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Probably the easiest way to do this is to use D-Bus to call the
org.gnome.Mutter.IdleMonitor.GetIdletimemethod on the/org/gnome/Mutter/IdleMonitor/Corepath oforg.gnome.Shell. That will give you the time in milliseconds that the shell has not seen any user input for.You can test this on the command line using:
You can use GIO’s D-Bus support from GJS to call the method from your extension. There’s an example here.