[SOLVED] Drive Icons - USB only

Using applications, configuring, problems
Post Reply
Message
Author
moonskin
Posts: 38
Joined: Sat 18 Oct 2008, 05:25
Location: Wollongong, Australia

[SOLVED] Drive Icons - USB only

#1 Post by moonskin »

We are using a locked down Puppy for our student netbooks in a high school (in Australia). We've got most of what we need worked out including authorised logon to an Enterprise grade Aruba wireless network.

The question I have (a nice "to do" but not a deal breaker) is whether it is possible to hide the drive icon for the HDD but show an icon for any USB drive that is inserted?

I've started having a good look at pup_event_frontend_d where I "think" the changes would have to be made but much of it is way beyond my skill level.

I suspect the answer may be in create_icon_func().

Any help would be appreciated.

Regards
Graham
Last edited by moonskin on Mon 06 May 2013, 10:57, edited 1 time in total.

moonskin
Posts: 38
Joined: Sat 18 Oct 2008, 05:25
Location: Wollongong, Australia

[SOLVED] Drive Icons - USB only

#2 Post by moonskin »

I found a solution that worked for me. I don't know if it has any other repercussions but I'll put it here. (so that you good folk don't need to waste time on it :) )

In the add_pinboard_func() section I've enclosed the code that adds the XML to the pinboard in a test for a usbdrive

The original code is (line 325)

Code: Select all

     
    echo "<?xml version=\"1.0\"?>
   <env:Envelope xmlns:env=\"http://www.w3.org/2001/12/soap-envelope\">
    <env:Body xmlns=\"http://rox.sourceforge.net/SOAP/ROX-Filer\">
     <PinboardAdd>
      <Path>/root/.pup_event/drive_${ONEDRVNAME}</Path>
      <X>${COORD_X}</X>
      <Y>${COORD_Y}</Y>
      <Label>${cutONEDRVNAME}</Label>
      <Args>${DRV_CATEGORY} ${FSTYPE}</Args>
     </PinboardAdd>
    </env:Body>
   </env:Envelope>"  | rox -R
Insert before the "echo ..." statement

Code: Select all

  if [ "$DRV_CATEGORY" = "usbdrv" ] 
then  
Insert a line after "| rox-R" (originally line 336) with

Code: Select all

fi
Regards
Graham

Post Reply