Custom Folders
Published on November 9, 2007 By DArnaez In ObjectDock
The creation of these "Scenarios" (as I call its) is a total success. I have new ideas but I need to know if it is possible with DesktopX technology or not. By the moment Scenarios are a set where wallpapers and icons are composed in the same 3D environment. So... you will have icons near you (bigger) and far (smaller)... to integrate in the space, the background simulate a floor and each icons have a reflection on it. But the icons (by the moment) are objects with typical targets (My CPU, My Documents, My Music).

I'm very close to finish a new version with Cryo64 Exodo YQ2 icons... but this time all icons have a mouser over animation. It look great!

THis is the new idea.
I would like to make a folder icon and when the user mouse over showing an animation like a (for example 640x480) window opened and with some icons inside (these icons linked to programs.
For example... the folder could be a Mozilla folder and inside the window you will find Firefox, Thunderbird, icons... or imagine a Stardock Folder! it would be great, I think.

Anybody know if this is possible?

Thanks in advance!


This is another sample
Comments (Page 1)
2 Pages1 2 
on Nov 09, 2007
looks very cool.



I do believe the folder with icons is possible.
on Nov 09, 2007
You have some amazing ideas Arnaez; definitely seems possible. Hope some of the DX masters will be able to help you out.

(These 640x480 windows...are you talking about drag and drop containers?)
on Nov 09, 2007
(These 640x480 windows...are you talking about drag and drop containers?)


Yeah!!! if that would be possible it would be great! or I could do an icons set or even using the icons that I made and convert it to objects. The only issue is the program location, because for example: typical user user have firefox at c:/Program Files/Mozilla/ but users like me using Windows XP 64 bit the target will be c:/Program Files (x86)/Mozilla

on Nov 09, 2007
Drag and drop containers:

Create object, set an image.
Go to Properties > General.
Click on 'change' object type.
Check 'Accepts Drag and Drop'.



However, if you want the dropped icons to be custom icons that would require creating(cloning actually) another object inside the container and then applying an image.

A few ideas on how to do this would be to use OnDropFiles and FileSystemObject to get the filepath/filename etc. Have a hidden object in the container that will be cloned and made visible OnDropFiles, and then maybe modify and use Quentin's shortcut method to set the shortcut and image.
I have no idea if this will work but hopefully it's a step in the right direction.
on Nov 09, 2007
Thanks to your help. However I can't reach the idea because I guess that method is for to give a folder as a target... and to put some shortcuts in that folder.. right?

I did a simple sample in Flash to show you the idea... pease go to This Link
on Nov 09, 2007
D. Arnaez I love the look of this, gives it the feel of 3d. Nice work, keep it.   
on Nov 09, 2007
Here's a regular drag and drop container example(that uses a script). Mouse over the folder to show the window (there's a 2 second delay). The window is set to close on any action.

Download LINK

Might try to make an example of the other method I mentioned if I have some time. I'm pretty sure what you want can be done; just haven't figured out how yet. LOL!


on Nov 09, 2007
Yep, it can be done. Add in a scripted animated png object.

Clicking the folder starts the animation then when the last frame is done or almost done have the container object fade in or whatever you want.

You could leave the animation on the last frame for the background.
on Nov 09, 2007
Ohhhh ... I see what you are talking about! You call a object "window" that is hidden. Question: dow?

I think we are on the way!!!

Thanks sViz abd SirSmiley!
on Nov 09, 2007
The one I created in the link consists of two objects the "icon" object and the "window" object.

In the "window" object, in the Properties > General tab, I set it to accept drag and drop like described earlier. Set visibility to 'no'. Then, in the Relation tab set 'Popup' to 'Menu(Close on any action)'.

The script is in the "icon" object. You'll see that I used the OnMouseEnter and OnMouseLeave functions to start and stop a timer that will make the "window" object visible after two seconds.

Like SirSmiley said, if you add a state with an animation to the "window" object, you can set it to that when it is made visible, so it can expand like in your flash.
on Nov 09, 2007
Ok Great... I'm rendering the window animation... but meanwhile... how should be a button to close the window? I have some experience in Flash but not in these codes... so I haven't idea how make that button appear in the last frame of the animation. The same is with the icons inside. How can I set that??
on Nov 09, 2007
There are two ways to go about it, after you add the animation state to the "window" object, and create the close button.

Use OnStateChanged. This procedure is called when a state has changed, in other words, after the animation finishes. It should go in the "window" object.


Sub OnStateChanged(state)
If state = "animatedstate" Then
DesktopX.Object("closebutton").visible = True
End If
End Sub


Then there's using scripted animations; it's a little more complicated.
Following the directions in the tutorial link, with a few modifications, you would simply check when the last frame is shown and then show the close button.


The same is with the icons inside.


The one I made used drag and drop so it would all appear once the window appears. However, if you are putting your own icons(seperate objects) in the window, you'd want to make sure they are either child objects or grouped. That way you could set the visibilty of them all using a loop.


Sub OnStateChanged(state)
If state = "animatedstate" Then
For each elem in DesktopX.Object("window").Children
elem.visible = True
Next
End If
End Sub




on Nov 10, 2007
Sorry to bother you again... but I don't know what I'm doing wrong. I put the animation replacing the White.png in the Window object. But when I make double click it open the "Desktop" folder... I know why but even leaving a white space in Location section... it open any folder system.

Please if you can help me would be great. Here I uploaded the .dxpack and the png files in a zip so please download it here

Thank you so much... I promise send you the DX theme when it will be ready... (if you want.. of course.. lol)
on Nov 10, 2007
I see the problem. You made the icon the child of the window. The window is set to close on any action so all of its children will inherit the 'close on any action' property, too. I cleared the Parent/Owner field as well as the group field, so the icon is unaffected.

I was re-reading your posts to get a better understanding of how you want this to function. I made several modifications and eliminated the complication of using a script. I just used state messages instead.

For the icon object:
-I added a mouse up state.
-The mouse up state has a message to set the window to the animation state

For the window object:
-I created an 'animation' state instead of using the default state.
-The animation state has a message to show the close button
-Also created a 'hide' state (which reverses the animation but you don't have to do that if that's not what you want)

For the close_window object:
-Added a mouse up state
-The mouse up state has messages to hide itself and the window.


So, a single click on the icon will open the window and close_window button. (A double click will open the folder shortcut.) A click on the close button will hide the button itself as well as the window.


DOWNLOAD LINK


Let me know if I'm misinterpreting your goal here.


I promise send you the DX theme when it will be ready... (if you want.. of course.. lol)


I'd be honored!
2 Pages1 2