Skip to content

Commit

Permalink
Display Toolbar as a mainWindow
Browse files Browse the repository at this point in the history
  • Loading branch information
rossetantoine committed Feb 26, 2014
1 parent 099103d commit dc65ef3
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 26 deletions.
4 changes: 3 additions & 1 deletion DCMView.m
Original file line number Diff line number Diff line change
Expand Up @@ -4955,6 +4955,8 @@ - (void)scrollWheel:(NSEvent *)theEvent
[[self windowController] propagateSettings];

[self setNeedsDisplay:YES];

[self displayIfNeeded];
}
}
}
Expand Down Expand Up @@ -6799,7 +6801,7 @@ -(void) sync:(NSNotification*)note
if( [[self windowController] windowWillClose])
return;

if( avoidRecursiveSync > 2) return;
if( avoidRecursiveSync > 0) return;
avoidRecursiveSync++;

if( [note object] != self && isKeyView == YES && matrix == 0 && curImage > -1)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,27 +91,3 @@ - (AppController*) appController
return [AppController sharedAppController];
}
@end
























6 changes: 5 additions & 1 deletion ToolBarNSWindow.m
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,13 @@

@implementation ToolBarNSWindow

- (void) resignMainWindow
{
}

- (BOOL) canBecomeMainWindow
{
return NO;
return YES;
}

- (BOOL) canBecomeKeyWindow
Expand Down
1 change: 1 addition & 0 deletions ToolbarPanel.m
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ - (id)initForViewer:(ViewerController *)v withToolbar:(NSToolbar *)t
[[self window] setAnimationBehavior: NSWindowAnimationBehaviorNone];
[[self window] setToolbar: toolbar];
[[self window] setLevel: NSNormalWindowLevel];
[[self window] makeMainWindow];

[toolbar setShowsBaselineSeparator: NO];
[toolbar setVisible: YES];
Expand Down
1 change: 1 addition & 0 deletions ViewerController.m
Original file line number Diff line number Diff line change
Expand Up @@ -8129,6 +8129,7 @@ -(void) changeImageData:(NSMutableArray*)f :(NSMutableArray*)d :(NSData*) v :(BO
[movieRateSlider setEnabled: NO];
[moviePosSlider setEnabled: NO];
[moviePlayStop setEnabled:NO];

[speedText setStringValue:[NSString stringWithFormat:NSLocalizedString(@"%0.1f im/s", @"im/s = images per second"), (float) [self frameRate]*direction]];

[seriesView setPixels:pixList[0] files:fileList[0] rois:roiList[0] firstImage: 0 level:'i' reset:!sameSeries];
Expand Down

0 comments on commit dc65ef3

Please sign in to comment.