Author Topic: Openbox right-click menu reloading  (Read 5888 times)

Offline djohnston

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 6227
  • I don't do Windows
Re: Openbox right-click menu reloading
« Reply #60 on: September 02, 2011, 05:05:01 PM »

Here is what I have in the /etc/xdg/autostart directory:
Quote
$ ls -l /etc/xdg/autostart
total 60
-rw-r--r-- 1 root root  210 avril 23 06:32 evolution-alarm-notify.desktop
-rw-r--r-- 1 root root 7220 avril  7 10:43 gdu-notification-daemon.desktop
-rw-r--r-- 1 root root 2791 sept. 30  2010 gnome-keyring-gpg.desktop
-rw-r--r-- 1 root root 5249 sept. 30  2010 gnome-keyring-pkcs11.desktop
-rw-r--r-- 1 root root 5000 sept. 30  2010 gnome-keyring-secrets.desktop
-rw-r--r-- 1 root root 4065 sept. 30  2010 gnome-keyring-ssh.desktop
-rw-r--r-- 1 root root 5535 avril  8 06:57 gsettings-data-convert.desktop
-rw-r--r-- 1 root root  291 nov.   9  2009 pam-panel-icon.desktop
-rw-r--r-- 1 root root 1111 janv.  2  2011 parcellite-startup.desktop
-rw-r--r-- 1 root root 4006 juin  21 12:39 user-dirs-update-gtk.desktop
-rw-r--r-- 1 root root  219 juin  14 23:05 volumeicon.desktop

Now that you are saying this, I wonder if it would not be wise to check this directory before remastering starting from the next quarterlies ? Should the ones which are at same time there and setup in .config/openbox/autostart.sh be systematically removed ?

Yes. The entries in /etc/xdg/autostart are new global session startup files. So, they should not be duplicated in the user's autostart.sh file.

What I can't understand is how my user-added autostart.sh entries (parcellite, wbar, guake and update-notifier) were recreated as desktop files in /etc/xdg/autostart. And why the qasmixer and net_applet entries were not.


 I could not see anymore where it was really going, and stopped trying to understand this complex process.


I think the "complex process" is a necessary evil in making the Openbox menus XDG-compliant. I also believe it could be streamlined somewhat. But, I haven't dug into the entire process yet.
Bare metal                           VBox
AMD Athlon 7750 Dual-Core    Single core
4GiB RAM                              1GiB RAM
nVidia GeForce FX 5200          64MB video
LXDE 32bit                            KDE 64bit

Registered Linux User #416378

Offline clarms

  • Full Member
  • ***
  • Posts: 72
Re: Openbox right-click menu reloading
« Reply #61 on: September 03, 2011, 12:08:21 AM »
So it seems for a temporary workaround to control one the entries, as in having one NOT run, is to remove the global entry in /etc/xdg/autostart and then comment or uncomment the choice in the ~/.config/openbox/autostart.sh. Is this right?

Offline djohnston

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 6227
  • I don't do Windows
Re: Openbox right-click menu reloading
« Reply #62 on: September 03, 2011, 12:48:06 AM »
So it seems for a temporary workaround to control one the entries, as in having one NOT run, is to remove the global entry in /etc/xdg/autostart and then comment or uncomment the choice in the ~/.config/openbox/autostart.sh. Is this right?


Because the desktop files Melodie ended up with in /etc/xdg/autostart directory are different than the set I ended up with, I cannot be sure what is supposed to be there by default.

Be on the safe side. As root, make a folder in /etc/xdg. I named mine /etx/xdg/autostart-moved. I then looked at what entries were in my ~/.config/openbox/autostart.sh file. If there was a desktop file that duplicated what was already in my autostart.sh file, I moved the desktop file to the folder named "autostart-moved".

Also be aware that the icon names you see in the /etc/xdg/autostart directory, when looking at the contents of that directory in the file browser, do not match the actual desktop file names. While looking at the directory, use the file manager to open a terminal window. Then you can list the actual desktop names.




I would be interested in your results. I am sure Melodie will be too.

Bare metal                           VBox
AMD Athlon 7750 Dual-Core    Single core
4GiB RAM                              1GiB RAM
nVidia GeForce FX 5200          64MB video
LXDE 32bit                            KDE 64bit

Registered Linux User #416378

Offline melodie

  • Hero Member
  • *****
  • Posts: 5942
  • XMMP=Jabber, free instant messaging protocol !
    • PCLinuxOS Fr
Re: Openbox right-click menu reloading
« Reply #63 on: September 03, 2011, 03:02:42 AM »
Hi,

djohnston, another way to make it safe, is to copy the whole directory foo to foo-backup as root, this way:

# cd /etc/xdg //we go to /etc/xdg
# cp -R autostart autostart-back //the directory is therefore created with the full content from the source directory

Then you can start to do what you need to in the autostart directory.

melodie at swissjabber dot ch - IRC #pclinuxos-fr sur freenode

Offline Yankee

  • Hero Member
  • *****
  • Posts: 1481
  • In theory, theory=practice, in practice ???
Re: Openbox right-click menu reloading
« Reply #64 on: September 11, 2011, 10:51:09 AM »

I applied a few changes in openbox-menu a few minutes ago. It uses now a 'synced' method for querying data to menucache lib. I think it should be better for refreshing the menu faster but the lack of documentation for menucache is not helping.


mimas,

How often is the user menu synced ?   The root openbox-menu is fine but my user openbox-menu
has some day old changes that haven't been "synced".   Everything has been updated as well.

THX.
ASUS EeePc 900HA netbook  1.6 Ghz Atom CPU  1GB RAM
160 GB internal HD    Seagate 250 GB USB portable drive 
Intel ‎Mobile 945GSE Integrated Graphics Controller
Atheros AR242x/AR542x Wireless Network Adapter
Intel (N10/ICH7 Family) High Definition Audio
Dynex 5-Button Wired Optical Mouse
LXDE

Offline melodie

  • Hero Member
  • *****
  • Posts: 5942
  • XMMP=Jabber, free instant messaging protocol !
    • PCLinuxOS Fr
Re: Openbox right-click menu reloading
« Reply #65 on: September 11, 2011, 11:50:13 AM »

I applied a few changes in openbox-menu a few minutes ago. It uses now a 'synced' method for querying data to menucache lib. I think it should be better for refreshing the menu faster but the lack of documentation for menucache is not helping.


mimas,

How often is the user menu synced ?   The root openbox-menu is fine but my user openbox-menu
has some day old changes that haven't been "synced".   Everything has been updated as well.

THX.

Hi,

You can move the $HOME/.cache/menu directory out of the way now, it will be recreated at once. Then look again to the menu entries which had not been sinced : if they are still there the problem comes from elsewhere (the /usr/share/applications directory where the desktop files live, for instance).

Regards,
Mélodie

melodie at swissjabber dot ch - IRC #pclinuxos-fr sur freenode

Offline Yankee

  • Hero Member
  • *****
  • Posts: 1481
  • In theory, theory=practice, in practice ???
Re: Openbox right-click menu reloading
« Reply #66 on: September 11, 2011, 12:28:52 PM »

You can move the $HOME/.cache/menu directory out of the way now, it will be recreated at once.


Yes, it immediately resynced then and is fine.  Installed 2 programs and then uninstalled them
and those changes synced at once also.  Have to remember this one, still haven't upgraded
my Bonsai  backup drive.

Thank You.

Patrick
ASUS EeePc 900HA netbook  1.6 Ghz Atom CPU  1GB RAM
160 GB internal HD    Seagate 250 GB USB portable drive 
Intel ‎Mobile 945GSE Integrated Graphics Controller
Atheros AR242x/AR542x Wireless Network Adapter
Intel (N10/ICH7 Family) High Definition Audio
Dynex 5-Button Wired Optical Mouse
LXDE

mimas

  • Guest
Re: Openbox right-click menu reloading
« Reply #67 on: September 11, 2011, 02:08:32 PM »
> How often is the user menu synced ?

Now it's every time it opens (every time openbox-menu is launched to be correct). The refresh for the old version was about seconds, not days.

As Mélodie wrote, you can delete ~/.cache/menu directory to force libmenu-cache to reread desktop files. It's theorically not needed but it can help when the menu is wrong or you need a quick refresh. I've done it only once or twice.
« Last Edit: September 11, 2011, 02:12:46 PM by mimas »

Offline djohnston

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 6227
  • I don't do Windows
Re: Openbox right-click menu reloading
« Reply #68 on: September 11, 2011, 02:25:06 PM »
mimas,

Thanks for your work on openbox-menu. It works flawlessly on my installations.

Bare metal                           VBox
AMD Athlon 7750 Dual-Core    Single core
4GiB RAM                              1GiB RAM
nVidia GeForce FX 5200          64MB video
LXDE 32bit                            KDE 64bit

Registered Linux User #416378

Offline Yankee

  • Hero Member
  • *****
  • Posts: 1481
  • In theory, theory=practice, in practice ???
Re: Openbox right-click menu reloading
« Reply #69 on: September 11, 2011, 03:42:51 PM »
> How often is the user menu synced ?

Now it's every time it opens (every time openbox-menu is launched to be correct). The refresh for the old version was about seconds, not days.

As Mélodie wrote, you can delete ~/.cache/menu directory  to force libmenu-cache to reread desktop files. It's theorically not needed but it can help when the menu is wrong or you need a quick refresh. I've done it only once or twice.

Well deleting the  ~/.cache/menu directory was an instant cure when launching openbox-menu was not.   So
deleting the  ~/.cache/menu directory  is the more powerful option when the menu refresh may stall.   All is well and
all the programs I needed are installed and remastered today.   Another happy customer.

Thanks for the info.

Patrick
ASUS EeePc 900HA netbook  1.6 Ghz Atom CPU  1GB RAM
160 GB internal HD    Seagate 250 GB USB portable drive 
Intel ‎Mobile 945GSE Integrated Graphics Controller
Atheros AR242x/AR542x Wireless Network Adapter
Intel (N10/ICH7 Family) High Definition Audio
Dynex 5-Button Wired Optical Mouse
LXDE