Skip to content
This repository has been archived by the owner on May 29, 2022. It is now read-only.

Commit

Permalink
removed dmrc and added csd-background-helper
Browse files Browse the repository at this point in the history
  • Loading branch information
angelescuo committed Jun 11, 2020
1 parent 8561027 commit 3c003c4
Show file tree
Hide file tree
Showing 6 changed files with 43 additions and 3 deletions.
34 changes: 34 additions & 0 deletions bin/csd-background-helper
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
#!/usr/bin/env bash
#
# Sets the following:
# [org.freedesktop.DisplayManager.AccountsService]
# BackgroundFile
# [User]
# Background
# in /var/lib/AccountsService/users/$USER

function setuserbackground(){
export USERBACKGROUND=`gsettings get org.cinnamon.desktop.background picture-filename | sed -e "s/^'//" -e "s/'$//"`

dbus-send --system --print-reply \
--dest=org.freedesktop.Accounts \
--type=method_call \
/org/freedesktop/Accounts/User`id -u` \
org.freedesktop.Accounts.User.SetBackgroundFile string:"$USERBACKGROUND"

dbus-send --system --print-reply \
--dest=org.freedesktop.Accounts \
/org/freedesktop/Accounts/User`id -u` \
org.freedesktop.DBus.Properties.Set \
string:org.freedesktop.DisplayManager.AccountsService \
string:BackgroundFile \
variant:string:"$USERBACKGROUND"
}

setuserbackground

dbus-monitor --profile "type='signal',interface='ca.desrt.dconf.Writer',path='/ca/desrt/dconf/Writer/user',arg0path='/org/cinnamon/desktop/background/'" |
while read -r line; do
setuserbackground
done

8 changes: 8 additions & 0 deletions etc/xdg/autostart/csd-background-helper.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
[Desktop Entry]
Type=Application
Name=Cinnamon Settings Daemon Background Helper
Comment=Sets the user background in AccountsService on Cinnamon
Exec=csd-background-helper
OnlyShowIn=CINNAMON;
X-CINNAMON-Autostart-enabled=true

2 changes: 0 additions & 2 deletions ghostbsd/etc/skel/dmrc

This file was deleted.

2 changes: 1 addition & 1 deletion schemas/91_org.cinnamon.theme.gschema.override
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[org.cinnamon.theme]
name='Ghomix'
name='Vimix-Dark'

0 comments on commit 3c003c4

Please sign in to comment.