[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: FileChooser private bookmarks doesn't seem to work
[Thread Prev] | [Thread Next]
- Subject: Re: FileChooser private bookmarks doesn't seem to work
- From: Bruce Steers <bsteers4@xxxxxxxxx>
- Date: Fri, 4 Oct 2024 02:02:53 +0100
- To: user@xxxxxxxxxxxxxxxxxxxxxx
On Thu, 3 Oct 2024 at 15:38, T Lee Davidson <t.lee.davidson@xxxxxxxxx>
wrote:
> On 10/1/24 23:45, Bruce Steers wrote:
> > I use this code...
> >
> > ' Gambas class file
> >
> > Public Sub Form_Open()
> >
> > Dim cc As New Collection[]
> >
> > If Exist("~/.config/gtk-3.0/bookmarks") Then
> > For Each sLine As String In
> Split(File.Load("~/.config/gtk-3.0/bookmarks"), "\n", Null, True)
> > Dim aVar As String[] = Split(sLine, " ", Null, True)
> > aVar.Insert(["", "", ""])
> > Dim c As New Collection
> > c["Path"] = Replace(FromUrl(aVar[0]), "file://", "")
> > If aVar[1] <> "" Then c["Name"] = aVar[1]
> > If aVar[2] <> "" Then c["Icon"] = aVar[2]
> > cc.Add(c)
> > Next
> >
> > Endif
> >
> > FileChooser1.Bookmarks = cc
> >
> > End
> >
> > In the attached picture you can see the FileChooser.Bookmarks list is
> filled but they do not show.
> >
> > The only way i can get any kind of bookmarks to show is by adding
> gb.settings for the user ones.
> >
> > Is it a bug or am i missing something?
> >
> > Respects
>
> I assume you are using GTK and that you mean the bookmark menu does not
> show as a MenuButton in the drop-down as documented at:
> https://gambaswiki.org/wiki/comp/gb.form/filechooser/bookmarks
>
> I used the code on that page and, with Qt5, get the same behavior as you.
> The Bookmarks menu item does not show.
>
Yep , i followed the same instructions. with no success. , pretty sure a
bug , i put on the bug tracker. I could't figure out the problem.
debugging the source i think the $hPrivate items are not updated, i put a
breakpoint where checks to add the $hPrivate contents but is seemed to only
do the check before i had set the items.
when it opens the Private bookmarks collection is present in the object but
the list hasn't added them.
> BTW, bookmarks-menu.png linked on that page is: not found.
>
hmm yeah i guess that's a bug in the wiki.
the filechooser/bookmarks page is a link to the dirview/bookmarks page.
--> ../../dirchooser/bookmarks
The page looks for
https://gambaswiki.org/wiki/comp/gb.form/filechooser/bookmarks/bookmarks-menu.png
I put a copy of the image where is expects it to be at that link and it
works.
But i should think that's a wiki bug.
> --
> Lee
>
Cheers Lee :)
BruceS
| Re: FileChooser private bookmarks doesn't seem to work | Bruce Steers <bsteers4@xxxxxxxxx> |
| Re: FileChooser private bookmarks doesn't seem to work | Bruce Steers <bsteers4@xxxxxxxxx> |
| FileChooser private bookmarks doesn't seem to work | Bruce Steers <bsteers4@xxxxxxxxx> |
| Re: FileChooser private bookmarks doesn't seem to work | T Lee Davidson <t.lee.davidson@xxxxxxxxx> |