Revision: 2954
http://skim-app.svn.sourceforge.net/skim-app/?rev=2954&view=rev
Author: hofman
Date: 2007-09-20 13:52:43 -0700 (Thu, 20 Sep 2007)
Log Message:
-----------
Select correct scale item in scale popup initially.
Don't blend splitview divider ends when using drawers.
Modified Paths:
--------------
trunk/BDSKZoomablePDFView.m
trunk/SKMainWindowController.m
trunk/SKSecondaryPDFView.m
Modified: trunk/BDSKZoomablePDFView.m
===================================================================
--- trunk/BDSKZoomablePDFView.m 2007-09-20 18:28:37 UTC (rev 2953)
+++ trunk/BDSKZoomablePDFView.m 2007-09-20 20:52:43 UTC (rev 2954)
@@ -142,14 +142,15 @@
[scalePopUpButton setTarget:self];
[scalePopUpButton setAction:@selector(scalePopUpAction:)];
+ // don't let it become first responder
+ [scalePopUpButton setRefusesFirstResponder:YES];
+
// Make sure the popup is big enough to fit the largest cell
- [scalePopUpButton setTitle:[[scalePopUpButton itemAtIndex:maxIndex]
title]];
+ cnt = [scalePopUpButton indexOfSelectedItem];
+ [scalePopUpButton selectItemAtIndex:maxIndex];
[scalePopUpButton sizeToFit];
- [scalePopUpButton synchronizeTitleAndSelectedItem];
+ [scalePopUpButton selectItemAtIndex:cnt];
- // don't let it become first responder
- [scalePopUpButton setRefusesFirstResponder:YES];
-
// put it in the scrollview
[scrollView addSubview:scalePopUpButton];
[scalePopUpButton release];
Modified: trunk/SKMainWindowController.m
===================================================================
--- trunk/SKMainWindowController.m 2007-09-20 18:28:37 UTC (rev 2953)
+++ trunk/SKMainWindowController.m 2007-09-20 20:52:43 UTC (rev 2954)
@@ -291,9 +291,7 @@
[rightSideContentBox addSubview:rightSideContentView];
[pdfView setFrame:[[pdfContentBox contentView] bounds]];
-
[secondaryPdfView setFrame:[[secondaryPdfContentBox contentView] bounds]];
- [pdfSplitView setBlendEnds:YES];
if (usesDrawers) {
NSSize size = [leftSideContentBox frame].size;
@@ -316,6 +314,8 @@
[rightSideDrawer openOnEdge:NSMaxXEdge];
[leftSideDrawer setDelegate:self];
[rightSideDrawer setDelegate:self];
+ } else {
+ [pdfSplitView setBlendEnds:YES];
}
[outlineView setAutoresizesOutlineColumn: NO];
Modified: trunk/SKSecondaryPDFView.m
===================================================================
--- trunk/SKSecondaryPDFView.m 2007-09-20 18:28:37 UTC (rev 2953)
+++ trunk/SKSecondaryPDFView.m 2007-09-20 20:52:43 UTC (rev 2954)
@@ -168,18 +168,19 @@
else
[self setScaleFactor:[self scaleFactor] adjustPopup:YES];
- // hook it up
- [scalePopUpButton setTarget:self];
- [scalePopUpButton setAction:@selector(scalePopUpAction:)];
-
// Make sure the popup is big enough to fit the largest cell
- [scalePopUpButton setTitle:[[scalePopUpButton itemAtIndex:maxIndex]
title]];
+ cnt = [scalePopUpButton indexOfSelectedItem];
+ [scalePopUpButton selectItemAtIndex:maxIndex];
[scalePopUpButton sizeToFit];
- [scalePopUpButton synchronizeTitleAndSelectedItem];
+ [scalePopUpButton selectItemAtIndex:cnt];
// don't let it become first responder
[scalePopUpButton setRefusesFirstResponder:YES];
+ // hook it up
+ [scalePopUpButton setTarget:self];
+ [scalePopUpButton setAction:@selector(scalePopUpAction:)];
+
// put it in the scrollview
[scrollView addSubview:scalePopUpButton];
[scalePopUpButton release];
@@ -211,9 +212,10 @@
[pagePopUpButton addItemWithTitle:label];
}
- [pagePopUpButton setTitle:[[pagePopUpButton itemAtIndex:maxIndex] title]];
+ i = [pagePopUpButton indexOfSelectedItem];
+ [pagePopUpButton selectItemAtIndex:maxIndex];
[pagePopUpButton sizeToFit];
- [pagePopUpButton synchronizeTitleAndSelectedItem];
+ [pagePopUpButton selectItemAtIndex:i];
[pagePopUpButton selectItemAtIndex:[pdfDoc indexForPage:[self
currentPage]]];
}
@@ -266,11 +268,9 @@
}
- (void)setAutoScales:(BOOL)newAuto adjustPopup:(BOOL)flag {
- if ([self autoScales] != newAuto) {
- [super setAutoScales:newAuto];
- if (newAuto && flag)
- [scalePopUpButton selectItemAtIndex:0];
- }
+ [super setAutoScales:newAuto];
+ if (newAuto && flag)
+ [scalePopUpButton selectItemAtIndex:0];
}
- (void)setScaleFactor:(float)newScaleFactor {
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit