Chris Muller uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-cmm.1011.mcz ==================== Summary ==================== Name: Morphic-cmm.1011 Author: cmm Time: 16 October 2015, 11:33:30.083 am UUID: cd841f83-985d-4bf9-b4bf-80bac0dd2b50 Ancestors: Morphic-mt.1010 - Improved keyboard support. "Desktop" command keys which are not overloaded by browsers are now available globally, so they can be accessed at any time (without needing to first give focus to the desktop). The following commands are now available globally: Command+Shift+O -> access a Monticello browser. Command+Shift+P -> access a Preferences browser. Command+Shift+Z -> browse the recent change log. Command+] -> save the image. Command+\ -> send the active window to the back. Command+Escape -> Close the active window (formerly Command+w). Control+Escape -> (new!) access the window list. - Encountered a gaggle of debuggers when dragging a Splitter with the mouse. It happened more than once, not sure why. Fixed with a guard. - HelpBrowsers now honor the Reuse Windows preference. =============== Diff against Morphic-mt.1010 =============== Item was changed: ----- Method: HandMorph>>sendListenEvent:to: (in category 'private events') ----- sendListenEvent: anEvent to: listenerGroup "Send the event to the given group of listeners" listenerGroup ifNil:[^self]. listenerGroup do:[:listener| + listener ifNotNil:[listener handleListenEvent: anEvent]].! - listener ifNotNil:[listener handleListenEvent: anEvent copy]].! Item was added: + ----- Method: HelpBrowser>>representsSameBrowseeAs: (in category '*morphic') ----- + representsSameBrowseeAs: anotherModel + ^ self hasUnacceptedEdits not and: + [ (toplevelTopics collect: + [ : e | e title ]) = + (anotherModel toplevelTopics collect: + [ : e | e title ]) ]! Item was changed: ----- Method: PasteUpMorph>>becomeActiveDuring: (in category 'initialization') ----- becomeActiveDuring: aBlock "Make the receiver the ActiveWorld during the evaluation of aBlock. Note that this method does deliberately *not* use #ensure: to prevent re-installation of the world on project switches." | priorWorld priorHand priorEvent | priorWorld := ActiveWorld. priorHand := ActiveHand. priorEvent := ActiveEvent. + priorHand removeEventListener: priorWorld. ActiveWorld := self. ActiveHand := self hands first. "default" ActiveEvent := nil. "not in event cycle" + ActiveHand addEventListener: self. aBlock on: Error do: [:ex | ActiveWorld := priorWorld. ActiveEvent := priorEvent. ActiveHand := priorHand. ex pass]! Item was added: + ----- Method: PasteUpMorph>>handleListenEvent: (in category 'events-processing') ----- + handleListenEvent: aUserInputEvent + "Handlers for *global* keys, regardless of which widget has keyboard focus." + aUserInputEvent type = #keystroke ifTrue: + [ aUserInputEvent commandKeyPressed ifTrue: + [ aUserInputEvent keyValue = $O asciiValue ifTrue: [ World findAMonticelloBrowser ]. + aUserInputEvent keyValue = $P asciiValue ifTrue: [ World findAPreferencesPanel: aUserInputEvent ]. + aUserInputEvent keyValue = $Z asciiValue ifTrue: [ ChangeList browseRecentLog ]. + aUserInputEvent keyValue = $] asciiValue ifTrue: + [ Smalltalk + snapshot: true + andQuit: false ] ] ]! Item was changed: ----- Method: ProportionalSplitterMorph>>updateFromEvent: (in category 'events') ----- updateFromEvent: anEvent | delta | + lastMouse ifNil: [ lastMouse := anEvent position ]. delta := splitsTopAndBottom ifTrue: [ 0 @ ((self normalizedY: anEvent cursorPoint y) - lastMouse y) ] ifFalse: [ (self normalizedX: anEvent cursorPoint x) - lastMouse x @ 0 ]. lastMouse := splitsTopAndBottom ifTrue: [ lastMouse x @ (self normalizedY: anEvent cursorPoint y) ] ifFalse: [ (self normalizedX: anEvent cursorPoint x) @ lastMouse y ]. self repositionBy: delta! Item was changed: ----- Method: SystemWindow>>activate (in category 'top window') ----- activate + "Bring the receiver to the top. If I am modal, bring along my owning window as well." + | modalOwner | + self modalChild ifNotNil: + [ : modalChild | modalChild owner ifNotNil: + [ modalChild activate. + ^ modalChild modalChild ifNil: [ modalChild flash ] ] ]. + (isCollapsed not and: + [ self paneMorphs size > 1 and: [ self splitters isEmpty ] ]) ifTrue: [ self addPaneSplitters ]. - "Activate the owner too." - - |mo mc| - mo := self modalOwner. - mc := self modalChild. - mc isNil - ifFalse: [mc owner notNil ifTrue: [ - mc activate. - ^mc modalChild isNil ifTrue: [mc flash]]]. - (isCollapsed not and: [ - self paneMorphs size > 1 and: [ - self splitters isEmpty ] ]) ifTrue: [ self addPaneSplitters ]. self activateWindow. + ActiveHand addKeyboardListener: self. + modalOwner := self modalOwner. + (modalOwner notNil and: [ modalOwner isSystemWindow ]) ifTrue: [ modalOwner bringBehind: self ]! - self rememberedKeyboardFocus - ifNil: [(self respondsTo: #navigateFocusForward) - ifTrue: [self navigateFocusForward]] - ifNotNil: [:m | m world - ifNil: [self rememberKeyboardFocus: nil] "deleted" - ifNotNil: [:w | - m wantsKeyboardFocus - ifTrue: [m takeKeyboardFocus] - ifFalse: [(self respondsTo: #navigateFocusForward) - ifTrue: [self navigateFocusForward]]]]. - (mo notNil and: [mo isSystemWindow]) - ifTrue: [mo bringBehind: self]! Item was changed: ----- Method: SystemWindow>>handleListenEvent: (in category 'events') ----- + handleListenEvent: aUserInputEvent + aUserInputEvent type = #keystroke ifTrue: + [ aUserInputEvent commandKeyPressed ifTrue: + [ aUserInputEvent keyValue = $\ asciiValue ifTrue: [ self class sendTopWindowToBack ]. + "Command+Escape" + aUserInputEvent keyValue = 27 ifTrue: + [ aUserInputEvent wasHandled: true. + ActiveHand removeKeyboardListener: self. + self delete ] ]. + aUserInputEvent controlKeyPressed ifTrue: + [ aUserInputEvent keyValue = 27 ifTrue: [ World findWindow: aUserInputEvent ] ] ]. + aUserInputEvent isMouse ifFalse: [ ^ self ]. + "Still dragging?" + aUserInputEvent hand hasSubmorphs ifTrue: [ ^ self ]. + "Make sure we lock our contents after drag-and-drop has finished." + (self isActive and: [ self class allWindowsAcceptInput not ]) ifFalse: [ self configureFocus ]. + aUserInputEvent hand removeMouseListener: self! - handleListenEvent: evt - "Make sure we lock our contents after DnD has finished" - evt isMouse ifFalse:[^self]. - evt hand hasSubmorphs ifTrue:[^self]. "still dragging" - (self isActive and: [ self class allWindowsAcceptInput not ]) ifFalse: [self configureFocus]. - evt hand removeMouseListener: self.! Item was changed: ----- Method: SystemWindow>>passivate (in category 'top window') ----- passivate "Lose my drop shadlow and reconfigure my focus according to preferences." self hasDropShadow: false ; configureFocus ; lookUnfocused. + ActiveHand removeKeyboardListener: self. model modelSleep! |
On 16.10.2015, at 16:33, [hidden email] wrote: > Chris Muller uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-cmm.1011.mcz > > ==================== Summary ==================== > > Name: Morphic-cmm.1011 > Author: cmm > Time: 16 October 2015, 11:33:30.083 am > UUID: cd841f83-985d-4bf9-b4bf-80bac0dd2b50 > Ancestors: Morphic-mt.1010 > > - Improved keyboard support. "Desktop" command keys which are not overloaded by browsers are now available globally, so they can be accessed at any time (without needing to first give focus to the desktop). > The following commands are now available globally: > Command+Shift+O -> access a Monticello browser. > Command+Shift+P -> access a Preferences browser. > Command+Shift+Z -> browse the recent change log. > Command+] -> save the image. > Command+\ -> send the active window to the back. > Command+Escape -> Close the active window (formerly Command+w). Why? It's CMD-W on osx and Alt-W on windows and Ctrl-W on Linux. Why change it _away_ form cmd-w? > Control+Escape -> (new!) access the window list. > - Encountered a gaggle of debuggers when dragging a Splitter with the mouse. It happened more than once, not sure why. Fixed with a guard. > - HelpBrowsers now honor the Reuse Windows preference. > > =============== Diff against Morphic-mt.1010 =============== > > Item was changed: |
In reply to this post by commits-2
Please allow the user to turn-off those global shortcuts via preferences. I need some of those in Vivide.
Best, Marcel |
In reply to this post by Tobias Pape
+1
Please do not change CMD+W. It has been "wipe current window" for so long on so many platforms... Best, Marcel |
In reply to this post by commits-2
I also don’t like this changes, not only the Cmd-W but the proliferetation of shortcuts, what is this, emacs?
> On Oct 16, 2015, at 11:34, [hidden email] wrote: > > Chris Muller uploaded a new version of Morphic to project The Trunk: > http://source.squeak.org/trunk/Morphic-cmm.1011.mcz > > ==================== Summary ==================== > > Name: Morphic-cmm.1011 > Author: cmm > Time: 16 October 2015, 11:33:30.083 am > UUID: cd841f83-985d-4bf9-b4bf-80bac0dd2b50 > Ancestors: Morphic-mt.1010 > > - Improved keyboard support. "Desktop" command keys which are not overloaded by browsers are now available globally, so they can be accessed at any time (without needing to first give focus to the desktop). > The following commands are now available globally: > Command+Shift+O -> access a Monticello browser. > Command+Shift+P -> access a Preferences browser. > Command+Shift+Z -> browse the recent change log. > Command+] -> save the image. > Command+\ -> send the active window to the back. > Command+Escape -> Close the active window (formerly Command+w). > Control+Escape -> (new!) access the window list. > - Encountered a gaggle of debuggers when dragging a Splitter with the mouse. It happened more than once, not sure why. Fixed with a guard. > - HelpBrowsers now honor the Reuse Windows preference. > > =============== Diff against Morphic-mt.1010 =============== > > Item was changed: > ----- Method: HandMorph>>sendListenEvent:to: (in category 'private events') ----- > sendListenEvent: anEvent to: listenerGroup > "Send the event to the given group of listeners" > listenerGroup ifNil:[^self]. > listenerGroup do:[:listener| > + listener ifNotNil:[listener handleListenEvent: anEvent]].! > - listener ifNotNil:[listener handleListenEvent: anEvent copy]].! > > Item was added: > + ----- Method: HelpBrowser>>representsSameBrowseeAs: (in category '*morphic') ----- > + representsSameBrowseeAs: anotherModel > + ^ self hasUnacceptedEdits not and: > + [ (toplevelTopics collect: > + [ : e | e title ]) = > + (anotherModel toplevelTopics collect: > + [ : e | e title ]) ]! > > Item was changed: > ----- Method: PasteUpMorph>>becomeActiveDuring: (in category 'initialization') ----- > becomeActiveDuring: aBlock > "Make the receiver the ActiveWorld during the evaluation of aBlock. > Note that this method does deliberately *not* use #ensure: to prevent > re-installation of the world on project switches." > | priorWorld priorHand priorEvent | > priorWorld := ActiveWorld. > priorHand := ActiveHand. > priorEvent := ActiveEvent. > + priorHand removeEventListener: priorWorld. > ActiveWorld := self. > ActiveHand := self hands first. "default" > ActiveEvent := nil. "not in event cycle" > + ActiveHand addEventListener: self. > aBlock > on: Error > do: [:ex | > ActiveWorld := priorWorld. > ActiveEvent := priorEvent. > ActiveHand := priorHand. > ex pass]! > > Item was added: > + ----- Method: PasteUpMorph>>handleListenEvent: (in category 'events-processing') ----- > + handleListenEvent: aUserInputEvent > + "Handlers for *global* keys, regardless of which widget has keyboard focus." > + aUserInputEvent type = #keystroke ifTrue: > + [ aUserInputEvent commandKeyPressed ifTrue: > + [ aUserInputEvent keyValue = $O asciiValue ifTrue: [ World findAMonticelloBrowser ]. > + aUserInputEvent keyValue = $P asciiValue ifTrue: [ World findAPreferencesPanel: aUserInputEvent ]. > + aUserInputEvent keyValue = $Z asciiValue ifTrue: [ ChangeList browseRecentLog ]. > + aUserInputEvent keyValue = $] asciiValue ifTrue: > + [ Smalltalk > + snapshot: true > + andQuit: false ] ] ]! > > Item was changed: > ----- Method: ProportionalSplitterMorph>>updateFromEvent: (in category 'events') ----- > updateFromEvent: anEvent > | delta | > + lastMouse ifNil: [ lastMouse := anEvent position ]. > delta := splitsTopAndBottom > ifTrue: [ 0 @ ((self normalizedY: anEvent cursorPoint y) - lastMouse y) ] > ifFalse: [ (self normalizedX: anEvent cursorPoint x) - lastMouse x @ 0 ]. > lastMouse := splitsTopAndBottom > ifTrue: [ lastMouse x @ (self normalizedY: anEvent cursorPoint y) ] > ifFalse: [ (self normalizedX: anEvent cursorPoint x) @ lastMouse y ]. > self repositionBy: delta! > > Item was changed: > ----- Method: SystemWindow>>activate (in category 'top window') ----- > activate > + "Bring the receiver to the top. If I am modal, bring along my owning window as well." > + | modalOwner | > + self modalChild ifNotNil: > + [ : modalChild | modalChild owner ifNotNil: > + [ modalChild activate. > + ^ modalChild modalChild ifNil: [ modalChild flash ] ] ]. > + (isCollapsed not and: > + [ self paneMorphs size > 1 and: [ self splitters isEmpty ] ]) ifTrue: [ self addPaneSplitters ]. > - "Activate the owner too." > - > - |mo mc| > - mo := self modalOwner. > - mc := self modalChild. > - mc isNil > - ifFalse: [mc owner notNil ifTrue: [ > - mc activate. > - ^mc modalChild isNil ifTrue: [mc flash]]]. > - (isCollapsed not and: [ > - self paneMorphs size > 1 and: [ > - self splitters isEmpty ] ]) ifTrue: [ self addPaneSplitters ]. > self activateWindow. > + ActiveHand addKeyboardListener: self. > + modalOwner := self modalOwner. > + (modalOwner notNil and: [ modalOwner isSystemWindow ]) ifTrue: [ modalOwner bringBehind: self ]! > - self rememberedKeyboardFocus > - ifNil: [(self respondsTo: #navigateFocusForward) > - ifTrue: [self navigateFocusForward]] > - ifNotNil: [:m | m world > - ifNil: [self rememberKeyboardFocus: nil] "deleted" > - ifNotNil: [:w | > - m wantsKeyboardFocus > - ifTrue: [m takeKeyboardFocus] > - ifFalse: [(self respondsTo: #navigateFocusForward) > - ifTrue: [self navigateFocusForward]]]]. > - (mo notNil and: [mo isSystemWindow]) > - ifTrue: [mo bringBehind: self]! > > Item was changed: > ----- Method: SystemWindow>>handleListenEvent: (in category 'events') ----- > + handleListenEvent: aUserInputEvent > + aUserInputEvent type = #keystroke ifTrue: > + [ aUserInputEvent commandKeyPressed ifTrue: > + [ aUserInputEvent keyValue = $\ asciiValue ifTrue: [ self class sendTopWindowToBack ]. > + "Command+Escape" > + aUserInputEvent keyValue = 27 ifTrue: > + [ aUserInputEvent wasHandled: true. > + ActiveHand removeKeyboardListener: self. > + self delete ] ]. > + aUserInputEvent controlKeyPressed ifTrue: > + [ aUserInputEvent keyValue = 27 ifTrue: [ World findWindow: aUserInputEvent ] ] ]. > + aUserInputEvent isMouse ifFalse: [ ^ self ]. > + "Still dragging?" > + aUserInputEvent hand hasSubmorphs ifTrue: [ ^ self ]. > + "Make sure we lock our contents after drag-and-drop has finished." > + (self isActive and: [ self class allWindowsAcceptInput not ]) ifFalse: [ self configureFocus ]. > + aUserInputEvent hand removeMouseListener: self! > - handleListenEvent: evt > - "Make sure we lock our contents after DnD has finished" > - evt isMouse ifFalse:[^self]. > - evt hand hasSubmorphs ifTrue:[^self]. "still dragging" > - (self isActive and: [ self class allWindowsAcceptInput not ]) ifFalse: [self configureFocus]. > - evt hand removeMouseListener: self.! > > Item was changed: > ----- Method: SystemWindow>>passivate (in category 'top window') ----- > passivate > "Lose my drop shadlow and reconfigure my focus according to preferences." > self > hasDropShadow: false ; > configureFocus ; > lookUnfocused. > + ActiveHand removeKeyboardListener: self. > model modelSleep! > > |
In reply to this post by Tobias Pape
On Sat, Oct 17, 2015 at 8:14 AM, Tobias Pape <[hidden email]> wrote:
Command+w has been to the desktop keys. I wanted Cmd+w for the global key too, but it is already overloaded by the editor for back-word. Back-word is overloaded with Shift+Control+[Left Arrow], but Cmd+w is nice for maintainig hand position while typing. |
In reply to this post by marcel.taeumel
Okay, can do. However I think we need to include the DockingBar shrtcuts together in that preference too, is that fair? That way, apps can have all the keys and register some of the shortcuts back, themselves if they want. On Sat, Oct 17, 2015 at 8:31 AM, marcel.taeumel <[hidden email]> wrote: Please allow the user to turn-off those global shortcuts via preferences. I |
In reply to this post by Chris Muller-3
On 18.10.2015, at 00:56, Chris Muller <[hidden email]> wrote: > On Sat, Oct 17, 2015 at 8:14 AM, Tobias Pape <[hidden email]> wrote: > > On 16.10.2015, at 16:33, [hidden email] wrote: > > > Chris Muller uploaded a new version of Morphic to project The Trunk: > > http://source.squeak.org/trunk/Morphic-cmm.1011.mcz > > > > ==================== Summary ==================== > > > > Name: Morphic-cmm.1011 > > Author: cmm > > Time: 16 October 2015, 11:33:30.083 am > > UUID: cd841f83-985d-4bf9-b4bf-80bac0dd2b50 > > Ancestors: Morphic-mt.1010 > > > > - Improved keyboard support. "Desktop" command keys which are not overloaded by browsers are now available globally, so they can be accessed at any time (without needing to first give focus to the desktop). > > The following commands are now available globally: > > Command+Shift+O -> access a Monticello browser. > > Command+Shift+P -> access a Preferences browser. > > Command+Shift+Z -> browse the recent change log. > > Command+] -> save the image. > > Command+\ -> send the active window to the back. > > Command+Escape -> Close the active window (formerly Command+w). > > Why? It's CMD-W on osx and Alt-W on windows and Ctrl-W on Linux. Why change it _away_ form cmd-w? > > > Command+w has been to the desktop keys. > > I wanted Cmd+w for the global key too, but it is already overloaded by the editor for back-word. Back-word is overloaded with Shift+Control+[Left Arrow], but Cmd+w is nice for maintainig hand position while typing. Thanks. I never understood why it is back-word… I just found it is back-word for readline (and hence most osx UI) but with ctrl-w. We really should rethink the meaning of CMD/ctrl/alt… Best regards -tobias F |
Hi Tobias,
> On Oct 17, 2015, at 10:53 PM, Tobias Pape <[hidden email]> wrote: > > >> On 18.10.2015, at 00:56, Chris Muller <[hidden email]> wrote: >> >> On Sat, Oct 17, 2015 at 8:14 AM, Tobias Pape <[hidden email]> wrote: >> >> On 16.10.2015, at 16:33, [hidden email] wrote: >> >>> Chris Muller uploaded a new version of Morphic to project The Trunk: >>> http://source.squeak.org/trunk/Morphic-cmm.1011.mcz >>> >>> ==================== Summary ==================== >>> >>> Name: Morphic-cmm.1011 >>> Author: cmm >>> Time: 16 October 2015, 11:33:30.083 am >>> UUID: cd841f83-985d-4bf9-b4bf-80bac0dd2b50 >>> Ancestors: Morphic-mt.1010 >>> >>> - Improved keyboard support. "Desktop" command keys which are not overloaded by browsers are now available globally, so they can be accessed at any time (without needing to first give focus to the desktop). >>> The following commands are now available globally: >>> Command+Shift+O -> access a Monticello browser. >>> Command+Shift+P -> access a Preferences browser. >>> Command+Shift+Z -> browse the recent change log. >>> Command+] -> save the image. >>> Command+\ -> send the active window to the back. >>> Command+Escape -> Close the active window (formerly Command+w). >> >> Why? It's CMD-W on osx and Alt-W on windows and Ctrl-W on Linux. Why change it _away_ form cmd-w? >> >> >> Command+w has been to the desktop keys. >> >> I wanted Cmd+w for the global key too, but it is already overloaded by the editor for back-word. Back-word is overloaded with Shift+Control+[Left Arrow], but Cmd+w is nice for maintainig hand position while typing. > > Thanks. > I never understood why it is back-word… I just found it is back-word for readline (and hence most osx UI) but with ctrl-w. > We really should rethink the meaning of CMD/ctrl/alt… +1 & try and make things consistent with VNC key mapping, Mac X server key mapping and Parallels coherence key mapping (etc?) so that things continue to work when running Linux and Windows images via X & parallels. We should be prepared to change the VM. And if it is there, it would be great to lift the mapping out of the VM. > Best regards > -tobias F > > > |
Free forum by Nabble | Edit this page |