Closed
Bug 80138
Opened 24 years ago
Closed 14 years ago
show native icons in directory viewer
Categories
(SeaMonkey :: UI Design, defect)
SeaMonkey
UI Design
Tracking
(Not tracked)
RESOLVED
WORKSFORME
People
(Reporter: alecf, Assigned: jag+mozilla)
References
Details
(Keywords: helpwanted)
Attachments
(1 file)
845 bytes,
patch
|
Details | Diff | Splinter Review |
it would be really cool if we could show native icons in the directory viewer.
Turns out it's incredibly simple. Attaching a one line patch
the only confusion I'm having is how to show a folder icon...
Reporter | ||
Comment 1•24 years ago
|
||
Comment 2•24 years ago
|
||
Does it work on Mac? :)
Reporter | ||
Comment 3•24 years ago
|
||
don't think so... you have to figure out how to get imglib to paint native
icons, and then hook them up to the moz-icon protocol
Comment 5•24 years ago
|
||
Yes it works on Mac. Simon you need to try out the mailnews client =). I'm
painting native mac and windows icons in the attachment pane.
moz-icon urls work on the Mac and on Windows. =)
Comment 6•24 years ago
|
||
Hmmm, interesting...
http://lxr.mozilla.org/mozilla/source/modules/libpr0n/decoders/icon/mac/
nsIconChannel.cpp
looks like there's a couple of slightly dodgy assumptions in there, like icons
being 8 bit never 24, and the only possible icon sizes being 16 and 32, but all
in all its a cool thing to have. Will file bugs on those if/when I see problems
stemming from those assumptions. The code uses PBDTGetIcon which is supported in
Carbon, though I wonder if some of the code would be more future proof (128x128
icons etc) if ported to use the newer IconServices APIs?
Comment 7•24 years ago
|
||
Yes, it should use Icon Services. And instead of reading the pixels directly, I
think it would be safer to draw to a GWorld, and convert that to an nsIImage.
Comment 8•24 years ago
|
||
Just FYI, I have patches (bug 78148) to move file:/// to html format, but they
probably won't be turned on for a while. My patches use the same icons ns4 does,
or would if they actually still worked (I'm about to file a bug on pav for that
- they did work not that long ago)
Comment 10•24 years ago
|
||
xp-apps - directory viewer
Component: Networking: File → XP Apps
QA Contact: tever → sairuh
Reporter | ||
Updated•24 years ago
|
Status: NEW → ASSIGNED
Priority: -- → P3
Target Milestone: --- → mozilla1.0
Comment 11•24 years ago
|
||
Alec: native Mac icon support bug is 66814 - has a patch, needs review.
I'd also repeat my comment: IconServices is a very nice modern API for doing this
and the existing code should probably be replaced by an IconServices
implementation.
Depends on: 66814
Comment 12•24 years ago
|
||
Note that we'll be moving to html soon for all the listings, at least until this
moves to outliner. After my patch, that uses the 4.7 icons, but if someone can
give me a url I can get them to use these instead.
Comment 13•24 years ago
|
||
Bradely, as I understand it this is about showing the directory browser for local
(file:///) URLs. So when it says "native icons" it means "the icon the file has
on my local disk here" rather than a set of generic document icons as FTP uses.
Comment 14•24 years ago
|
||
yes, but as of tomorrow (hopefully) file (and gopher) will follow the pref which
ftp does for whether to use xul or html for directory listings - see bug 78148
And I'd like to do this, too, if you can give me a way which will work on all
platforms.
Comment 15•24 years ago
|
||
OK cool - then I think that depends which way you want to go - if you have an
nsIImage for the icon you want to show and you need a native mac icon, then you
need the patch I linked in the bug above.
However, I think its much more likely that you have a URL pointing to the file on
disk you want to display the icon for? In that case I think the protocol moz-
icon: can be used to display the correct icon for the file, and you shouldn't
have to do anything other than generate URLs in the right format.
I'm not sure what one needs to put in the URL exactly... possibly the path of a
file on disk? From the first patch on this bug I think not.
I just tried that in yesterday's build (typing it into the URL bar on Mac OS) and
it didn't work. So, anyone know precisely what needs to be done?
Comment 16•23 years ago
|
||
Bugs targeted at mozilla1.0 without the mozilla1.0 keyword moved to mozilla1.0.1
(you can query for this string to delete spam or retrieve the list of bugs I've
moved)
Target Milestone: mozilla1.0 → mozilla1.0.1
Reporter | ||
Updated•23 years ago
|
Target Milestone: mozilla1.0.1 → mozilla1.2alpha
Reporter | ||
Comment 17•23 years ago
|
||
this would be cool, but the directory viewer isn't even used anymore. futuring
for now, but I still think it would be neat. Hopefully someone else will take
the reins on this...
Keywords: helpwanted
Target Milestone: mozilla1.2alpha → Future
Updated•20 years ago
|
Product: Core → Mozilla Application Suite
Comment 18•17 years ago
|
||
Was this (patch) fixed/included in bug 113742 patch !?
See
<http://bonsai.mozilla.org/cvsblame.cgi?file=/mozilla/suite/common/directory/directory.xul&rev=1.40&mark=47-48#24>
Assignee: alecf → jag
Status: ASSIGNED → NEW
Priority: P3 → --
QA Contact: bugzilla
Target Milestone: Future → ---
Comment 19•17 years ago
|
||
Well, I just tried it, and no native icons appear in Firefox or Camino. So if it was ever fixed then it's broken again.
![]() |
||
Comment 20•14 years ago
|
||
WORKSFORME: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b12pre) Gecko/20110212 Firefox/4.0b12pre SeaMonkey/2.1b3pre
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → WORKSFORME
![]() |
||
Comment 21•14 years ago
|
||
Fixed in either Bug 131393 and/or Bug 129327.
You need to log in
before you can comment on or make changes to this bug.
Description
•