Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Retrieving Shell Icons

Reply
Thread Tools

Retrieving Shell Icons

 
 
Francesco
Guest
Posts: n/a
 
      02-18-2004
Hello,

(sorry, I have already asked this, but it is still unsolved)

I want to display the icons associated with a given extensions
(also parent folder and folder) for my little filemanager in a
virtual list control.

I know, wxMimeTypesManager, unfortunatly, I cannot use it (i need
indexes
beginning from zero for the imagelist, and I'm not able to get
directory icons)

With win32 extension, I didn't come clear also:

The indexes, which i get from:

dwFlags = Globals.SHGFI_USEFILEATTRIBUTES |
Globals.SHGFI_SYSICONINDEX | Globals.SHGFI_SMALLICON |
Globals.SHGFI_ICON
windll.shell32.SHGetFileInfo (item.GetName(),
win32con.FILE_ATTRIBUTE_NORMAL,
byref(Globals.shfileinfo), sizeof(Globals.shfileinfo), dwFlags)
item.m_nIconIdx = Globals.shfileinfo.iIcon

(for example 9 for exe's, 8 html, 7 txt, 4 directories ...)

should correspond to the icons in the list

dwFlags = Globals.SHGFI_USEFILEATTRIBUTES |
Globals.SHGFI_SYSICONINDEX | Globals.SHGFI_SMALLICON
m_hImageList = windll.shell32.SHGetFileInfo('.txt',
win32file.FILE_ATTRIBUTE_NORMAL, byref(Globals.shfileinfo),
sizeof(Globals.shfileinfo), dwFlags)

In wxwindow, it is easy; but in wxPython (?)

Problem is: i get only a int pointer to the iconlist.
Can I transform this, to pass it into the image list; or is there
another solution?

Thank you for any help!

--
Francesco
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
show desktop icons missing under arrange icons by JoAnna Windows 64bit 15 03-10-2009 08:23 AM
Re: How to pass shell variable to shell script from python Christian Heimes Python 0 02-27-2008 10:53 AM
Sometimes Explorer vanishes along with the icons, but the icons come back Desdemona@Verona.com Computer Support 1 12-06-2007 03:17 AM
JTree and those small Icons ahead folder, file etc icons. Richie Williams Java 5 10-25-2007 05:01 PM
can I run unix shell command in the ModelSim shell? clinton__bill@hotmail.com VHDL 2 02-18-2005 10:04 PM



Advertisments