- Registriert
- 20.03.08
- Beiträge
- 476
Liebe Community!
Ich programmiere gerade an einem Status Bar Programm.
An sich funktioniert das ganz gut.
Jetzt versuche ich allerdings nicht die Funktionalität einzubauen, dass eine bestimmte Aktion ausgeführt wird, wenn ich auf das Icon vom Programm klicke.
Folgendes habe ich schon ausprobiert:
Leider wird die Aktion einfach nicht ausgeführt!!
Kann mir da vielleicht jemand helfen?
Vielen Dank
LG
…
Ich programmiere gerade an einem Status Bar Programm.
An sich funktioniert das ganz gut.
Jetzt versuche ich allerdings nicht die Funktionalität einzubauen, dass eine bestimmte Aktion ausgeführt wird, wenn ich auf das Icon vom Programm klicke.
Folgendes habe ich schon ausprobiert:
Code:
[COLOR=#3f217c][COLOR=#4b8186]statusItem[/COLOR][COLOR=#000000] = [[[[/COLOR][COLOR=#7340a3]NSStatusBar[/COLOR][COLOR=#000000] [/COLOR]systemStatusBar[COLOR=#000000]] [/COLOR]statusItemWithLength[COLOR=#000000]:[/COLOR][COLOR=#7a482f]NSVariableStatusItemLength[/COLOR][COLOR=#000000]] [/COLOR]retain[COLOR=#000000]];[/COLOR][/COLOR]
[COLOR=#3f217c][COLOR=#000000][[/COLOR][COLOR=#4b8186]statusItem[/COLOR][COLOR=#000000] [/COLOR]setHighlightMode[COLOR=#000000]:[/COLOR][COLOR=#bf2e9d]YES[/COLOR][COLOR=#000000]];[/COLOR][/COLOR]
[COLOR=#4b8186][COLOR=#000000][[/COLOR]statusItem[COLOR=#000000] [/COLOR][COLOR=#3f217c]setMenu[/COLOR][COLOR=#000000]:[/COLOR]theMenu[COLOR=#000000]];[/COLOR][/COLOR]
[[COLOR=#4b8186]theMenu[/COLOR] [COLOR=#3f217c]setAction[/COLOR]:[COLOR=#bf2e9d]@selector[/COLOR](update:)];
Leider wird die Aktion einfach nicht ausgeführt!!
Kann mir da vielleicht jemand helfen?
Vielen Dank
LG
…