NSString * nodeKeyPath;
NSString * contentKeyPath;
id selectedObject;
-
+ BOOL fullScreen;
+
/* Actions on non-node items*/
id target;
SEL action;
@property (readonly, retain) id selectedObject;
+@property (readwrite) BOOL fullScreen;
+
/* Set up a specific action to do, on items that don't have node.
* action first argument is the browsableVideoView. You can get the selected object,
* with -selectedObject */
- (NSArray *)itemsTree {
return itemsTree;
}
+
- (void)setItemsTree:(NSArray *)newItemsTree
{
[itemsTree release];
[self changeSelectedPath:[[[NSIndexPath alloc] init] autorelease] withSelectedIndex:0];
}
+- (BOOL)fullScreen
+{
+ return [super isInFullScreenMode];
+}
+
+- (void)setFullScreen:(BOOL)newFullScreen
+{
+ if( newFullScreen == self.fullScreen )
+ return;
+
+ if( newFullScreen )
+ {
+ [super enterFullScreenMode:[[self window] screen] withOptions:nil];
+ }
+ else
+ {
+ [super exitFullScreenModeWithOptions:nil];
+ }
+}
+
/* Initializer */
- (void)awakeFromNib
{
//[self changeSelectedIndex:0];
}
-
/* Hiding/Displaying the menu */
- (void)hideMenu
[self changeSelectedIndex:selectedIndex+1];
}
+- (void)mouseDown:(NSEvent *)theEvent
+{
+ if([theEvent clickCount] != 2)
+ return;
+
+ self.fullScreen = !self.fullScreen;
+}
+
- (void)keyDown:(NSEvent *)theEvent
{
if(([[theEvent charactersIgnoringModifiers] characterAtIndex:0] == 13) && menuDisplayed)