~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to www/media/browser/browser.js

  • Committer: drtomc
  • Date: 2008-02-01 04:13:23 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:369
Add stuff on installing and configuring pound.

Show diffs side-by-side

added added

removed removed

Lines of Context:
60
60
 
61
61
/* Mapping SVN status to icons, just the file's basename */
62
62
svn_icons = {
63
 
    "unversioned": "unversioned.png",
 
63
    "unversioned": null,
64
64
    "normal": "normal.png",
65
65
    "added": "added.png",
66
66
    "missing": "missing.png",
81
81
    "conflicted": "Permanent file (conflicted)",
82
82
};
83
83
 
84
 
default_svn_icon = "modified.png";
 
84
default_svn_icon = null;
85
85
default_svn_nice = "Unknown status";
86
86
 
87
87
svn_icons_path = "media/images/svn";
88
88
 
 
89
published_icon = "media/images/interface/published.png";
 
90
 
89
91
/* List of MIME types considered "executable" by the system.
90
92
 * Executable files offer a "run" link, implying that the "serve"
91
93
 * application can interpret them.
340
342
    var dom_path = document.getElementById("path");
341
343
    var href_path = make_path(this_app);
342
344
    var nav_path = "";
 
345
    var dir;
343
346
 
344
347
    /* Also set the document title */
345
348
    document.title = path_basename(path) + " - IVLE";
346
349
    /* Create all of the paths */
347
 
    for each (var dir in path.split("/"))
 
350
    var pathlist = path.split("/");
 
351
    for (var i=0; i<pathlist.length; i++)
348
352
    {
 
353
        dir = pathlist[i];
349
354
        if (dir == "") continue;
350
355
        /* Make an 'a' element */
351
356
        href_path = path_join(href_path, dir);
380
385
/** Given an svnstatus, returns the path to the icon.
381
386
 * \param type String, svn status.
382
387
 * \return Path to the icon. Has applied make_path, so it is relative to site
383
 
 * root.
 
388
 * root. May return null to indicate no SVN icon.
384
389
 */
385
390
function svnstatus_to_icon(svnstatus)
386
391
{
389
394
        filename = svn_icons[svnstatus];
390
395
    else
391
396
        filename = default_svn_icon;
 
397
    if (filename == null) return null;
392
398
    return make_path(path_join(svn_icons_path, filename));
393
399
}
394
400