Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide



Rockbox mail archive

Subject: RE: Bookmark Files
From: Benjamin (mailinglists_at_samuraipanda.com)
Date: 2003-01-17


Um, way more complex then I wanna do :-).

Essentially the way it works now is this:
1. Each bookmark file is kept in the same directory as file it's
associated with (\artist\pink floyd\tracks.m3u has a file in the same
directory called tracks.m3u.bmark). I'm avoiding a centralized
directory because I don't want to figure out how to handle duplicate
names (\artist\skinny puppies\tracks.m3u would give the same bookmark
name as the above example if it were centralized, tracks.m3u.bmark).
Call me lazy :-).
2. This file can have 10 bookmarks (actually it can have any number
more, but I gave a hard stop at 10 just for fun). Each bookmark
contains various information, including index (in the case of M3Us) and
elapsed time.
3. The multi-resume leverages this file by reserving the first line of
the file for its information (which is just a bookmark). If auto-load
bookmark (resume) is enabled, it will look for the .bmark file and if it
finds it, will load the first bookmark in that file.
4. There are two new settings, Enable AutoBookmark and Enable Autoload
Bookmark. Both have "Yes", "No", and "Ask" and are how #3 works.
        4.1 Enable AutoBookmark enables the resume feature that
leverages bookmarks. Set it to Yes, and it will automatically write the
resume information. No disables it. Ask prompts the user.
        4.2 Enable Autoload will enable the checking in 3 and depending
on the setting will automatically load, prompt the user, or never load.
5. I coded out a bookmark menu today. Select the .bmark file in the
directory explorer and that bookmark file is read in and the first
bookmark is displayed, with the index (for M3Us) and the elapsed time.
Click PLAY to select that bookmark. Click UP or DOWN to show the next
or previous bookmark. I may add the MP3 information name also. I'll
decide tomorrow. I'm not going to do much more with the menu beyond
this.

The more I think about it, the more I prefer the single bookmark file
vs. my original design, which was one file for bookmarks, one for resume
information. The original design just had to many files floating around
(the MP3, the .resume, and the .bmark). I'll post an updated patch
Friday with these changes.

Ben



Page was last modified "Jan 10 2012" The Rockbox Crew
aaa