overdue-scratch

Author Topic: [Implemented] GUI extra graphics for selected device  (Read 102694 times)

0 Members and 1 Guest are viewing this topic.

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: GUI extra graphics for selected device
« Reply #30 on: July 06, 2010, 06:17:20 PM »
Sorry for the absence, Blackosx. Been busy and there wasn't much more we could rumble here.
No need to apologise Azimuth as your enthusiasm for this has been encouraging. And yes I agree, the project was at a crossroads and needed some injection from the code guru's and now hopefully Zef can produce something with it.

EDIT: I've had another look at the code and think I might personally be able to implement the conditional use of a rollover theme whilst still catering for conventional themes. I just need to somehow find a few spare quiet hours...  If I do then I will post what I come up with, but at the same time I don't want to duplicate efforts if Zef is also looking at it..

EDIT: I now have my own branch on the SVN.. :)
The plan will be to make the required adjustments to the code for old and new theme compatability. I had an hour on it last night and I have it working with either an old or new theme, but I need to test thoroughly and implement error catching so it behaves correctly when there is a missing file. Once I am satisfied I have a working model, I will commit the changes to my branch.

After that, I might look at other tweaks which can be done to the GUI?
« Last Edit: July 08, 2010, 01:34:45 PM by Blackosx »
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: GUI extra graphics for selected device
« Reply #31 on: July 08, 2010, 11:37:47 PM »
The rollover functionality now works along side using existing themes and I have commit the code to my branch. :)

They way it works is this:
For rollover functionality to exist, seven extra rollover device images, identified by a '_o' at the end of the filename, should be added to a theme folder. So they will be:
device_cdrom_o.png
device_ext3_o.png
device_fat16_o.png
device_fat32_o.png
device_generic_o.png
device_hfsplus_o.png
device_ntfs_o.png

When the theme is loaded, the selected device will be replaced with the rollover version. The traditional device_selection will still also be drawn, so it can be used to enhance the theme still or if you don't want to use it you make this an empty graphic in the theme then it won't be seen.

If any of the seven extra graphic files are missing from the theme folder then the booter will default to working normally, so when a device is highlighted in the GUI, the device_selection graphic will be drawn under the device and no image replacement will occur.

Note: At this time, compiling with an embedded theme will fail as I haven't added additional rollover graphics in to the artwork folder. But then again, adding the extra images in the artwork folder for compiling with and embedded theme will result in the file size exceeding the limit.

10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

smith@@

  • Member
  • Posts: 49
Re: GUI extra graphics for selected device
« Reply #32 on: July 09, 2010, 12:19:48 AM »
Thanks azimuth and Great.. It would be amazing if you or anyone else would be happy to help tweak this idea/piece of code to make it more workable/presentable and I know valv expressed an interest in it too which was nice.  Then I will be happy to work on extra graphics.... I have been working on trying to finalise the device icons for my glass ball theme... Here is what I have so far:



Now i have try the new rev 175 and it works well, but i want these icons :P

« Last Edit: July 09, 2010, 08:35:55 AM by smith@@ »

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: GUI extra graphics for selected device
« Reply #33 on: July 09, 2010, 08:11:27 AM »
Now i have try the new rev 175 and it works well, but i would these icons :P
Hi smith@@

Thanks for testing, and yes, I will have to get to work now on sorting a theme with the above icons and also working on other themes..  :P
But, if desired, extra device icons can also be added to existing themes....  I might try doing a couple for examples.
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Re: GUI extra graphics for selected device
« Reply #34 on: July 09, 2010, 02:46:14 PM »
Hum... Blackosx, on the themes without rollover images, it seems the device_selection.png is being drawn on "top" of device_*.png instead of "below"!? I can only see device_selection.png on a selected device.

Going to lunch and then see if i can understand this stuff :) ttyl
« Last Edit: July 09, 2010, 08:05:16 PM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: GUI extra graphics for selected device
« Reply #35 on: July 09, 2010, 03:16:09 PM »
Thanks for testing it Azimuth and thanks for the feedback.

That's interesting because having the device_selection drawn on top was something I had on the to-do list as I remember somebody asking for that in the the feature request section... But I hadn't got round to that yet  :)

However, on my system the device selection behaviour is as it's always been (I think). What theme are you using?
« Last Edit: July 09, 2010, 03:47:18 PM by Blackosx »
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Re: GUI extra graphics for selected device
« Reply #36 on: July 09, 2010, 04:57:55 PM »
My pleasure mate ;)

Ok, based on your answer i compiled the booter from your branch, tested and it behaves normally!.. sorry for misleading feedback.

Previous feedback was based on the booter i use; probably some side effect of the edits to fit in AutoResolution patch, as even with the AutoResolution=n i get the behavior i mentioned. It's the only patch i have that messes with Gui stuff. You know, i'm not 100% sure if device_selection is being drawn on "top" or "instead"... doing some more testing...

p.s.: device_selection is being drawn "instead", not on top. So, it's doing the rollover using only device_selection.png :P interesting stuff indeed!.. and confusing...
« Last Edit: July 09, 2010, 09:09:48 PM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: GUI extra graphics for selected device
« Reply #37 on: July 09, 2010, 05:42:48 PM »
p.s.: device_selection is being drawn "instead", not on top. So, it's doing the rollover using only device_selection.png :P interesting stuff indeed!
I'm not sure I understand. What theme are you using? If it's a rollover theme, has it got all the extra graphics?
The test theme I supplied in the first post should work, though I will update that theme with a more complete version once it's ready.
« Last Edit: July 09, 2010, 05:49:08 PM by Blackosx »
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Re: GUI extra graphics for selected device
« Reply #38 on: July 09, 2010, 06:11:37 PM »
LoL, i knew i'd get you confused :) clearing...
Using the booter from your branch, both types of themes work fine, no problems at all (beside the one you mentioned).

The "weird" behavior is using the patch on the booter i use; on themes without rollover image, device_selection.png is used as rollover image.

« Last Edit: July 09, 2010, 06:15:15 PM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: GUI extra graphics for selected device
« Reply #39 on: July 09, 2010, 06:26:22 PM »
Thanks for helping me understand  ;D

As for your issue with your booter, if you have previously applied the diff that I posted in the first post then I think what you're seeing will happen with normal themes. I suggest you look at the changes I made yesterday to gui.c in my branch on the SVN. You should look at the LoadThemeImage function and the drawDeviceList function.
« Last Edit: July 09, 2010, 06:32:20 PM by Blackosx »
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Re: GUI extra graphics for selected device
« Reply #40 on: July 09, 2010, 08:38:22 PM »
yeah.. i missed the changes on drawDeviceList  :o should have lunched before checking this out  ;D
I'm sorry about the confusion; i've been prodigal at it, lately.
I was reviewing the changes and i was like "what's this rolloverfail for??.. then i stopped to read your last post and there was light, "i haven't done any editing on drawDeviceList!".

Ok, nice work!  :)
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

smith@@

  • Member
  • Posts: 49
Re: GUI extra graphics for selected device
« Reply #41 on: July 13, 2010, 09:58:23 AM »
Hey black, i have add your mod to the valv boot, last rev 177 from svn, but i have these error in compilation:


Quote
boot.c: In function ‘common_boot’:
boot.c:354: warning: implicit declaration of function ‘initGUI’
boot.c:409: warning: implicit declaration of function ‘drawBackground’

I've see that there are the differences. I've try to fix them but i'm not sure. Something of your mod contrasts with it?

gives you a 'look if you can ;)

Thanks

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: GUI extra graphics for selected device
« Reply #42 on: July 13, 2010, 10:58:57 AM »
Hi smith@@

I am no expert at this by any means, but have you definitely added all the changes I made? including the one to gui.h?
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

Blackosx

  • Forum Moderator
  • Posts: 1150
Re: GUI extra graphics for selected device
« Reply #43 on: July 13, 2010, 11:30:41 AM »
...I will have to get to work now on sorting a theme with the above icons and also working on other themes..  :P
I have been beavering away to get a theme released for this, and here's a preview of where's it at and this shows the theme with the device icons in the de-selected state. It's almost finished and should be out in a day or so..
 


UPDATE:
Here it is.. Blackosx_GlassEye_Theme, a complete theme for using with this mod.  For testing purposes, I will add the compiled boot file from my branch here too for users who aren't sure about compiling Chameleon. I'll do it a bit later when I get to an Intel Mac.

Note: the compiled modified boot file which is required for using this theme is at the bottom of the first post.
To use these new files, you will need a build of Chameleon RC5 r254 onwards.
« Last Edit: July 26, 2010, 10:51:06 AM by Blackosx »
10.10.5 / 10.11 GM1 | Asus Maximum IV Gene-Z | i7-2600 3.40GHz | 4GB | Radeon 5770 1GB

nesnfsn

  • Observer
  • Posts: 24
Re: GUI extra graphics for selected device
« Reply #44 on: July 13, 2010, 06:09:05 PM »
Blackosx, please bear with me as sometimes I am slow.

I looked through your most recently post, downloaded the attached theme.zip, and unarchived it on my office G4. Could you please explain to me the purpose for 2 files - device_chameleon.png and device_chameleon_0.png? The purpose for each of other extra optional device icons is crystal clear. These, not so much.

Thanks,

nesnfsn in Sunny South Florida