Лэйн
4 Sep 2009, 9:56 PM
Hi!
I try to understand the functionality of the Desktop and try to implement now a function of relogin: the user changes the account (log out and then log in).
I need to clean user data after a user exits the application (i.e. clean the desktop).
I tried the code
for (Shortcut s : desktop.getShortcuts())
desktop.removeShortcut(s);
for (Window w : desktop.getWindows())
desktop.removeWindow(w);
but it does not work. When I relogin, the number of shortcuts is doubled.
How to clean the Desktop?
Can someone help me?
Thank you in advance.
Sorry for my bad English.
I try to understand the functionality of the Desktop and try to implement now a function of relogin: the user changes the account (log out and then log in).
I need to clean user data after a user exits the application (i.e. clean the desktop).
I tried the code
for (Shortcut s : desktop.getShortcuts())
desktop.removeShortcut(s);
for (Window w : desktop.getWindows())
desktop.removeWindow(w);
but it does not work. When I relogin, the number of shortcuts is doubled.
How to clean the Desktop?
Can someone help me?
Thank you in advance.
Sorry for my bad English.