← Back to team overview

cairo-dock-team team mailing list archive

[Bug 995634] Re: Bookmark name in thunar wrong when shortcut added on plugin

 

Thank you, that was my next step but I hadn't looked up what the
bookmark file was yet. Thanks for making that much easier.

Long story short the shortcut plugin is sending a newline before it
sends the file link to the .gtk-bookmarks file and no newline after the
file link. Nautilus ignores this error but thunar and PCManFM do not.

The details of my testing are below:

With just 2 Folders in the thunar bookmark pane Downloads and Documents.
When I do cat on the .gtk-bookmarks file it shows:

brian@gibralter:~$ cat .gtk-bookmarks
file:///home/brian/Downloads
file:///home/brian/Documents
brian@gibralter:~$

 I added the folder Conky by dragging to the shortcut plugin and the
left pane in thunar shows Downloads, Documents and nts (instead of
Conky. I have a screen shot if you need to see it -> bookmarks-
debug1.png).  Doing cat on .gtk-bookmarks shows that a new line was
inserted before the Conky link and no new line was inserted after the
conky link:

brian@gibralter:~$ cat .gtk-bookmarks 
file:///home/brian/Downloads
file:///home/brian/Documents

file:///home/brian/Conkybrian@gibralter:~$

Notice that the command line returns to the end of the cat because there
is no new line.

If I add Videos by dragging to the shortcut thunar shows Downloads,
Documents, Conky, ts (instead of Videos. I have a screen shot if you
need to see it -> bookmarks-debug2.png). Cat shows:

brian@gibralter:~$ cat .gtk-bookmarks 
file:///home/brian/Downloads
file:///home/brian/Documents

file:///home/brian/Conky
file:///home/brian/Videosbrian@gibralter:~$

There is now a newline at the end of the Conky link (I presume it was
put there ahead of the Videos link instead of after).  If I now add a
bookmark through thunar (drag Music to the left thunar pane) the
newlines get reset but notice the link for the Video file. It has the
"ts" at the end as if that is the name of the shortcut and in thunar the
name for the Video bookmark is "ts" but the link is correct (I have a
screen shot if you need to see it -> bookmark-debug3.png).

brian@gibralter:~$ cat .gtk-bookmarks 
file:///home/brian/Downloads
file:///home/brian/Documents
file:///home/brian/Conky
file:///home/brian/Videos ts
file:///home/brian/Music
brian@gibralter:~$ 

If I now add a folder by dragging (openbravopos-database) to the shorcut
plugin the newline issue is back (I have a screen shot if you need to
see it -> bookmark-debug4.png). The name in thunar is garbage
characters.

brian@gibralter:~$ cat .gtk-bookmarks 
file:///home/brian/Downloads
file:///home/brian/Documents
file:///home/brian/Conky
file:///home/brian/Videos ts
file:///home/brian/Music

file:///home/brian/openbravopos-databasebrian@gibralter:~$

Now I tried the exact same steps with nautilus and here is the cat
results before the dragging of the Music folder using nautilus dragging
to the left pane. Notice that the drags to the shortcut plugin still
results in the newline issue. Nautilus ignores this error and notice
that using nautilus to drag to the left pane it puts the link and the
shortcut name not just the link like thunar does. Nautilus even does the
new line reset when I drag the Music folder over to the left pane and
the newline returns when dragging the openbravo folder to the shortcut
plugin.

Just as a side note the file manager PCManFM 0.9.9 shows the blank
newline as a root link ("/").

So nautilus handles the errors and thunar does not handle the problem
very well but there is definitely an issue with the shortcuts plugin and
newlines (it is just not noticed because most people use nautilus and it
has better error correction).

Also, it does not matter if I restart thunar (I had tried that before)
because as we now determined the issue is in the .gtk-bookmark file.

As I said before this does not bother me because I do not use the
bookmarks this way but the info may be of use to you.

-- 
You received this bug notification because you are a member of Cairo-
Dock Team, which is subscribed to Cairo-Dock Plug-ins.
https://bugs.launchpad.net/bugs/995634

Title:
  Bookmark name in thunar wrong when shortcut added on plugin

Status in Cairo-Dock: Plug-ins:
  New

Bug description:
  I posted this in the forums but the thread is marked resolved so I
  thought I should report a bug and let you decide if it is an issue and
  to see if anyone can confirm the issue (personally I don't add
  shortcuts this way because if I have thunar open already it is just as
  easy to drag and drop in thunar's left pane but it came up during
  testing for someone's issue).

  When I drop a folder on the shortcuts it gets added to both the
  shortcuts plugin and thunar but thunar shows an odd name. I tried it
  again yesterday (May 4th, 2012) and same thing, the bookmark was
  added, cairo-dock showed the correct name and opened the correct
  folder but thunar showed random characters for the name but opened the
  correct folder. All I had to do was right click in thunar and rename
  the bookmark and everything was fine. (I just tried a number of times
  and sometimes the name is fine but most times there are random names
  and/or characters showing in thunar)

  xubuntu 11.04 
  cairo-dock 3.0 (added using ppa)
  opengl 
  regular xfdesktop (no compiz)
  Thunar 1.2.1

To manage notifications about this bug go to:
https://bugs.launchpad.net/cairo-dock-plug-ins/+bug/995634/+subscriptions


References