The Trunk: Morphic-cmm.682.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: Morphic-cmm.682.mcz

commits-2
Chris Muller uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-cmm.682.mcz

==================== Summary ====================

Name: Morphic-cmm.682
Author: cmm
Time: 16 September 2013, 6:31:14.281 pm
UUID: 60de2e35-7faa-45d7-a153-ee2bc1e0676f
Ancestors: Morphic-cmm.681

- Don't let a smart-splitter cross the hand when mouseOverForKeyboardFocus is on, so the intended keyboard focus will be maintained.

=============== Diff against Morphic-cmm.681 ===============

Item was added:
+ ----- Method: ProportionalSplitterMorph>>proposedCorrectionWouldCauseFocusChange: (in category 'layout') -----
+ proposedCorrectionWouldCauseFocusChange: correction
+ ^ Preferences mouseOverForKeyboardFocus and:
+ [ | edge | splitsTopAndBottom
+ ifTrue:
+ [ edge := correction positive
+ ifTrue: [ self bottom + 3 ]
+ ifFalse: [ self top - 3 ].
+ ActiveHand position y
+ inRangeOf: edge
+ and: edge + correction ]
+ ifFalse:
+ [ edge := correction positive
+ ifTrue: [ self right ]
+ ifFalse: [ self left ].
+ ActiveHand position x
+ inRangeOf: edge
+ and: edge + correction ] ]!

Item was changed:
  ----- Method: ProportionalSplitterMorph>>step (in category 'events') -----
  step
  | correction |
  splitsTopAndBottom
  ifTrue:
  [ (correction := self topBottomCorrection) isZero
+ ifTrue:
+ [ self class smartHorizontalSplitters ifFalse: [ self stopStepping ] ]
+ ifFalse:
+ [ (self proposedCorrectionWouldCauseFocusChange: correction)
+ ifFalse: [ self repositionBy: 0 @ correction ] ] ]
- ifTrue: [ self class smartHorizontalSplitters ifFalse: [ self stopStepping ] ]
- ifFalse: [ self repositionBy: 0 @ correction ] ]
  ifFalse:
  [ correction := self leftRightImbalance.
  correction abs > 1
  ifTrue:
+ [ (self proposedCorrectionWouldCauseFocusChange: correction)
+ ifFalse:
+ [ self repositionBy:
+ (correction abs > 4
+ ifTrue: [ correction sign * 2 @ 0 ]
+ ifFalse: [ correction sign @ 0 ]) ] ]
- [ self repositionBy:
- (correction abs > 4
- ifTrue: [ correction sign * 2 @ 0 ]
- ifFalse: [ correction sign @ 0 ]) ]
  ifFalse:
  [ self class smartVerticalSplitters ifFalse: [ self stopStepping ] ] ]!