The Trunk: Morphic-mt.1542.mcz

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

The Trunk: Morphic-mt.1542.mcz

commits-2
Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-mt.1542.mcz

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

Name: Morphic-mt.1542
Author: mt
Time: 25 September 2019, 11:25:42.543838 am
UUID: 7ef7fdda-3074-144f-8ff7-a728dbfc50a2
Ancestors: Morphic-mt.1541

Now that we have an MVC parent project and the project name is visible in the main docking bar, make that label clickable to open the change sorter. :-)

=============== Diff against Morphic-mt.1541 ===============

Item was added:
+ ----- Method: DockingBarMorph>>addUpdatingItem: (in category 'construction') -----
+ addUpdatingItem: aBlock
+ | item |
+ item := DockingBarUpdatingItemMorph new.
+ aBlock value: item.
+ self addMorphBack: item!

Item was added:
+ ----- Method: DockingBarMorph>>items (in category 'accessing') -----
+ items
+
+ ^ submorphs select: [:m | m isKindOf: MenuItemMorph]!

Item was added:
+ UpdatingMenuItemMorph subclass: #DockingBarUpdatingItemMorph
+ instanceVariableNames: ''
+ classVariableNames: ''
+ poolDictionaries: ''
+ category: 'Morphic-Menus-DockingBar'!

Item was added:
+ ----- Method: DockingBarUpdatingItemMorph>>decorateOwner (in category 'as yet unclassified') -----
+ decorateOwner
+
+ "Ignore."!

Item was added:
+ ----- Method: DockingBarUpdatingItemMorph>>mouseEnter: (in category 'as yet unclassified') -----
+ mouseEnter: evt
+ "Do not hover docking bar items directory. Mouse-down required. But if you already see a submenu, support hovering."
+
+ owner selectedItem ifNotNil: [owner selectItem: self event: evt]!

Item was added:
+ ----- Method: TheWorldMainDockingBar>>browseChanges (in category 'right side') -----
+ browseChanges
+
+ ChangeSorter open.!

Item was added:
+ ----- Method: TheWorldMainDockingBar>>browseChangesLabel (in category 'right side') -----
+ browseChangesLabel
+ "The project name is the same as the current change set."
+
+ ^ Project current name!

Item was changed:
  ----- Method: TheWorldMainDockingBar>>createDockingBar (in category 'construction') -----
  createDockingBar
  "Create a docking bar from the receiver's representation"
 
  | dockingBar |
  dockingBar := DockingBarMorph new
  adhereToTop;
  borderWidth: 0.
  self fillDockingBar: dockingBar.
+ "self labelIfNeeded: dockingBar."
- self labelIfNeeded: dockingBar.
  ^ dockingBar!

Item was removed:
- ----- Method: TheWorldMainDockingBar>>labelIfNeeded: (in category 'private') -----
- labelIfNeeded: aDockingBar
- "Label the given docking bar with the project name, if needed"
- (aDockingBar submorphWithProperty: #projectNameMorph)
- contents: (Project current isTopProject ifTrue: [''] ifFalse: [Project current name]);
- fitContents!

Item was changed:
  ----- Method: TheWorldMainDockingBar>>projectNameOn: (in category 'right side') -----
  projectNameOn: aDockingBar
+
+ aDockingBar addUpdatingItem: [:item |
+ item
+ help: 'Browse this project''s changes';
+ target: self;
+ selector: #browseChanges;
+ wordingProvider: self
+ wordingSelector: #browseChangesLabel].!
- | morph |
- morph := StringMorph contents: ''.
- morph
- color: (self userInterfaceTheme textColor ifNil: [Color black]);
- font: (self userInterfaceTheme font ifNil: [TextStyle defaultFont]).
- morph setProperty: #projectNameMorph toValue: #projectNameMorph.
- aDockingBar addMorphBack: morph.
- self labelIfNeeded: aDockingBar!

Item was changed:
  ----- Method: TheWorldMainDockingBar>>updateIfNeeded: (in category 'private') -----
  updateIfNeeded: aDockingBar
  "Update the given docking bar if needed"
  | timeStamp |
  timeStamp := aDockingBar
  valueOfProperty: #mainDockingBarTimeStamp
  ifAbsent: [].
  timeStamp ~= self class timeStamp
  ifTrue:
  [aDockingBar
  release;
  removeAllMorphs.
+ self fillDockingBar: aDockingBar]!
- self fillDockingBar: aDockingBar]
- ifFalse:
- [self labelIfNeeded: aDockingBar]!

Item was added:
+ ----- Method: UpdatingMenuItemMorph>>decorateOwner (in category 'world') -----
+ decorateOwner
+
+ MenuIcons decorateMenu: owner.!

Item was changed:
  ----- Method: UpdatingMenuItemMorph>>updateContents (in category 'world') -----
  updateContents
  "Update the receiver's contents"
 
  | newString enablement nArgs |
  ((wordingProvider isNil) or: [wordingSelector isNil]) ifFalse: [
  nArgs := wordingSelector numArgs.
  newString := nArgs = 0
  ifTrue:
  [wordingProvider perform: wordingSelector]
  ifFalse:
  [(nArgs = 1 and: [wordingArgument notNil])
  ifTrue:
  [wordingProvider perform: wordingSelector with: wordingArgument]
  ifFalse:
  [nArgs == arguments size ifTrue:
  [wordingProvider perform: wordingSelector withArguments: arguments]]].
  newString = (self contentString ifNil: [ contents ])
  ifFalse: [self contents: newString.
+ self decorateOwner ]].
- MenuIcons decorateMenu: owner ]].
  enablementSelector ifNotNil:
  [(enablement := self enablement) == isEnabled
  ifFalse: [self isEnabled: enablement]]!


Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: Morphic-mt.1542.mcz

Hannes Hirzel
Hello Marcel

I have updated my image to Image Squeak5.3alpha  latest update: #18984

I have
   Project current name 'Top'
   Project current isTopProject  true

   Project current parent a MorphicProject (Top) in a
PasteUpMorph(2434915) [world]

I do not see this label for an MVC parent project.
Under which conditions will this appear?

Regards
Hannes

On Wed, 25 Sep 2019 09:25:49 0000, [hidden email]
<[hidden email]> wrote:

> Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
> http://source.squeak.org/trunk/Morphic-mt.1542.mcz
>
> ==================== Summary ====================
>
> Name: Morphic-mt.1542
> Author: mt
> Time: 25 September 2019, 11:25:42.543838 am
> UUID: 7ef7fdda-3074-144f-8ff7-a728dbfc50a2
> Ancestors: Morphic-mt.1541
>
> Now that we have an MVC parent project and the project name is visible in
> the main docking bar, make that label clickable to open the change sorter.
> :-)
>
> =============== Diff against Morphic-mt.1541 ===============
>
> Item was added:
> + ----- Method: DockingBarMorph>>addUpdatingItem: (in category
> 'construction') -----
> + addUpdatingItem: aBlock
> + | item |
> + item := DockingBarUpdatingItemMorph new.
> + aBlock value: item.
> + self addMorphBack: item!
>
> Item was added:
> + ----- Method: DockingBarMorph>>items (in category 'accessing') -----
> + items
> +
> + ^ submorphs select: [:m | m isKindOf: MenuItemMorph]!
>
> Item was added:
> + UpdatingMenuItemMorph subclass: #DockingBarUpdatingItemMorph
> + instanceVariableNames: ''
> + classVariableNames: ''
> + poolDictionaries: ''
> + category: 'Morphic-Menus-DockingBar'!
>
> Item was added:
> + ----- Method: DockingBarUpdatingItemMorph>>decorateOwner (in category 'as
> yet unclassified') -----
> + decorateOwner
> +
> + "Ignore."!
>
> Item was added:
> + ----- Method: DockingBarUpdatingItemMorph>>mouseEnter: (in category 'as
> yet unclassified') -----
> + mouseEnter: evt
> + "Do not hover docking bar items directory. Mouse-down required. But if
> you already see a submenu, support hovering."
> +
> + owner selectedItem ifNotNil: [owner selectItem: self event: evt]!
>
> Item was added:
> + ----- Method: TheWorldMainDockingBar>>browseChanges (in category 'right
> side') -----
> + browseChanges
> +
> + ChangeSorter open.!
>
> Item was added:
> + ----- Method: TheWorldMainDockingBar>>browseChangesLabel (in category
> 'right side') -----
> + browseChangesLabel
> + "The project name is the same as the current change set."
> +
> + ^ Project current name!
>
> Item was changed:
>   ----- Method: TheWorldMainDockingBar>>createDockingBar (in category
> 'construction') -----
>   createDockingBar
>   "Create a docking bar from the receiver's representation"
>  
>   | dockingBar |
>   dockingBar := DockingBarMorph new
>   adhereToTop;
>   borderWidth: 0.
>   self fillDockingBar: dockingBar.
> + "self labelIfNeeded: dockingBar."
> - self labelIfNeeded: dockingBar.
>   ^ dockingBar!
>
> Item was removed:
> - ----- Method: TheWorldMainDockingBar>>labelIfNeeded: (in category
> 'private') -----
> - labelIfNeeded: aDockingBar
> - "Label the given docking bar with the project name, if needed"
> - (aDockingBar submorphWithProperty: #projectNameMorph)
> - contents: (Project current isTopProject ifTrue: [''] ifFalse: [Project
> current name]);
> - fitContents!
>
> Item was changed:
>   ----- Method: TheWorldMainDockingBar>>projectNameOn: (in category 'right
> side') -----
>   projectNameOn: aDockingBar
> +
> + aDockingBar addUpdatingItem: [:item |
> + item
> + help: 'Browse this project''s changes';
> + target: self;
> + selector: #browseChanges;
> + wordingProvider: self
> + wordingSelector: #browseChangesLabel].!
> - | morph |
> - morph := StringMorph contents: ''.
> - morph
> - color: (self userInterfaceTheme textColor ifNil: [Color black]);
> - font: (self userInterfaceTheme font ifNil: [TextStyle defaultFont]).
> - morph setProperty: #projectNameMorph toValue: #projectNameMorph.
> - aDockingBar addMorphBack: morph.
> - self labelIfNeeded: aDockingBar!
>
> Item was changed:
>   ----- Method: TheWorldMainDockingBar>>updateIfNeeded: (in category
> 'private') -----
>   updateIfNeeded: aDockingBar
>   "Update the given docking bar if needed"
>   | timeStamp |
>   timeStamp := aDockingBar
>   valueOfProperty: #mainDockingBarTimeStamp
>   ifAbsent: [].
>   timeStamp ~= self class timeStamp
>   ifTrue:
>   [aDockingBar
>   release;
>   removeAllMorphs.
> + self fillDockingBar: aDockingBar]!
> - self fillDockingBar: aDockingBar]
> - ifFalse:
> - [self labelIfNeeded: aDockingBar]!
>
> Item was added:
> + ----- Method: UpdatingMenuItemMorph>>decorateOwner (in category 'world')
> -----
> + decorateOwner
> +
> + MenuIcons decorateMenu: owner.!
>
> Item was changed:
>   ----- Method: UpdatingMenuItemMorph>>updateContents (in category 'world')
> -----
>   updateContents
>   "Update the receiver's contents"
>
>   | newString enablement nArgs |
>   ((wordingProvider isNil) or: [wordingSelector isNil]) ifFalse: [
>   nArgs := wordingSelector numArgs.
>   newString := nArgs = 0
>   ifTrue:
>   [wordingProvider perform: wordingSelector]
>   ifFalse:
>   [(nArgs = 1 and: [wordingArgument notNil])
>   ifTrue:
>   [wordingProvider perform: wordingSelector with: wordingArgument]
>   ifFalse:
>   [nArgs == arguments size ifTrue:
>   [wordingProvider perform: wordingSelector withArguments:
> arguments]]].
>   newString = (self contentString ifNil: [ contents ])
>   ifFalse: [self contents: newString.
> + self decorateOwner ]].
> - MenuIcons decorateMenu: owner ]].
>   enablementSelector ifNotNil:
>   [(enablement := self enablement) == isEnabled
>   ifFalse: [self isEnabled: enablement]]!
>
>
>

Reply | Threaded
Open this post in threaded view
|

Re: The Trunk: Morphic-mt.1542.mcz

marcel.taeumel
Extras > Rebuild Menus


Best,
Marcel

Am 25.09.2019 12:35:26 schrieb H. Hirzel <[hidden email]>:

Hello Marcel

I have updated my image to Image Squeak5.3alpha latest update: #18984

I have
Project current name 'Top'
Project current isTopProject true

Project current parent a MorphicProject (Top) in a
PasteUpMorph(2434915) [world]

I do not see this label for an MVC parent project.
Under which conditions will this appear?

Regards
Hannes

On Wed, 25 Sep 2019 09:25:49 0000, [hidden email]
wrote:
> Marcel Taeumel uploaded a new version of Morphic to project The Trunk:
> http://source.squeak.org/trunk/Morphic-mt.1542.mcz
>
> ==================== Summary ====================
>
> Name: Morphic-mt.1542
> Author: mt
> Time: 25 September 2019, 11:25:42.543838 am
> UUID: 7ef7fdda-3074-144f-8ff7-a728dbfc50a2
> Ancestors: Morphic-mt.1541
>
> Now that we have an MVC parent project and the project name is visible in
> the main docking bar, make that label clickable to open the change sorter.
> :-)
>
> =============== Diff against Morphic-mt.1541 ===============
>
> Item was added:
> + ----- Method: DockingBarMorph>>addUpdatingItem: (in category
> 'construction') -----
> + addUpdatingItem: aBlock
> + | item |
> + item := DockingBarUpdatingItemMorph new.
> + aBlock value: item.
> + self addMorphBack: item!
>
> Item was added:
> + ----- Method: DockingBarMorph>>items (in category 'accessing') -----
> + items
> +
> + ^ submorphs select: [:m | m isKindOf: MenuItemMorph]!
>
> Item was added:
> + UpdatingMenuItemMorph subclass: #DockingBarUpdatingItemMorph
> + instanceVariableNames: ''
> + classVariableNames: ''
> + poolDictionaries: ''
> + category: 'Morphic-Menus-DockingBar'!
>
> Item was added:
> + ----- Method: DockingBarUpdatingItemMorph>>decorateOwner (in category 'as
> yet unclassified') -----
> + decorateOwner
> +
> + "Ignore."!
>
> Item was added:
> + ----- Method: DockingBarUpdatingItemMorph>>mouseEnter: (in category 'as
> yet unclassified') -----
> + mouseEnter: evt
> + "Do not hover docking bar items directory. Mouse-down required. But if
> you already see a submenu, support hovering."
> +
> + owner selectedItem ifNotNil: [owner selectItem: self event: evt]!
>
> Item was added:
> + ----- Method: TheWorldMainDockingBar>>browseChanges (in category 'right
> side') -----
> + browseChanges
> +
> + ChangeSorter open.!
>
> Item was added:
> + ----- Method: TheWorldMainDockingBar>>browseChangesLabel (in category
> 'right side') -----
> + browseChangesLabel
> + "The project name is the same as the current change set."
> +
> + ^ Project current name!
>
> Item was changed:
> ----- Method: TheWorldMainDockingBar>>createDockingBar (in category
> 'construction') -----
> createDockingBar
> "Create a docking bar from the receiver's representation"
>
> | dockingBar |
> dockingBar := DockingBarMorph new
> adhereToTop;
> borderWidth: 0.
> self fillDockingBar: dockingBar.
> + "self labelIfNeeded: dockingBar."
> - self labelIfNeeded: dockingBar.
> ^ dockingBar!
>
> Item was removed:
> - ----- Method: TheWorldMainDockingBar>>labelIfNeeded: (in category
> 'private') -----
> - labelIfNeeded: aDockingBar
> - "Label the given docking bar with the project name, if needed"
> - (aDockingBar submorphWithProperty: #projectNameMorph)
> - contents: (Project current isTopProject ifTrue: [''] ifFalse: [Project
> current name]);
> - fitContents!
>
> Item was changed:
> ----- Method: TheWorldMainDockingBar>>projectNameOn: (in category 'right
> side') -----
> projectNameOn: aDockingBar
> +
> + aDockingBar addUpdatingItem: [:item |
> + item
> + help: 'Browse this project''s changes';
> + target: self;
> + selector: #browseChanges;
> + wordingProvider: self
> + wordingSelector: #browseChangesLabel].!
> - | morph |
> - morph := StringMorph contents: ''.
> - morph
> - color: (self userInterfaceTheme textColor ifNil: [Color black]);
> - font: (self userInterfaceTheme font ifNil: [TextStyle defaultFont]).
> - morph setProperty: #projectNameMorph toValue: #projectNameMorph.
> - aDockingBar addMorphBack: morph.
> - self labelIfNeeded: aDockingBar!
>
> Item was changed:
> ----- Method: TheWorldMainDockingBar>>updateIfNeeded: (in category
> 'private') -----
> updateIfNeeded: aDockingBar
> "Update the given docking bar if needed"
> | timeStamp |
> timeStamp := aDockingBar
> valueOfProperty: #mainDockingBarTimeStamp
> ifAbsent: [].
> timeStamp ~= self class timeStamp
> ifTrue:
> [aDockingBar
> release;
> removeAllMorphs.
> + self fillDockingBar: aDockingBar]!
> - self fillDockingBar: aDockingBar]
> - ifFalse:
> - [self labelIfNeeded: aDockingBar]!
>
> Item was added:
> + ----- Method: UpdatingMenuItemMorph>>decorateOwner (in category 'world')
> -----
> + decorateOwner
> +
> + MenuIcons decorateMenu: owner.!
>
> Item was changed:
> ----- Method: UpdatingMenuItemMorph>>updateContents (in category 'world')
> -----
> updateContents
> "Update the receiver's contents"
>
> | newString enablement nArgs |
> ((wordingProvider isNil) or: [wordingSelector isNil]) ifFalse: [
> nArgs := wordingSelector numArgs.
> newString := nArgs = 0
> ifTrue:
> [wordingProvider perform: wordingSelector]
> ifFalse:
> [(nArgs = 1 and: [wordingArgument notNil])
> ifTrue:
> [wordingProvider perform: wordingSelector with: wordingArgument]
> ifFalse:
> [nArgs == arguments size ifTrue:
> [wordingProvider perform: wordingSelector withArguments:
> arguments]]].
> newString = (self contentString ifNil: [ contents ])
> ifFalse: [self contents: newString.
> + self decorateOwner ]].
> - MenuIcons decorateMenu: owner ]].
> enablementSelector ifNotNil:
> [(enablement := self enablement) == isEnabled
> ifFalse: [self isEnabled: enablement]]!
>
>
>