Patrick Rein uploaded a new version of Morphic to project The Trunk:
http://source.squeak.org/trunk/Morphic-pre.1229.mcz
==================== Summary ====================
Name: Morphic-pre.1229
Author: pre
Time: 4 August 2016, 12:40:48.215407 pm
UUID: 4d9cc4e1-e64b-f946-8a54-1e329d9e4d5a
Ancestors: Morphic-mt.1228
Fixes the handling of block provided answers to send out the message instead of the window title and to deal with a request for the default value.
=============== Diff against Morphic-mt.1228 ===============
Item was changed:
----- Method: DialogWindow>>getUserResponse (in category 'running') -----
getUserResponse
| hand world |
+ (ProvideAnswerNotification signal: self message asString)
+ ifNotNil: [:answer|
+ ^ answer = #default
+ ifTrue: [result]
+ ifFalse: [answer]].
- (ProvideAnswerNotification signal: self title asString) ifNotNil: [:answer| ^ answer].
self message ifEmpty: [messageMorph delete]. "Do not waste space."
self paneMorph submorphs ifEmpty: [self paneMorph delete]. "Do not waste space."
hand := self currentHand.
world := self currentWorld.
self fullBounds.
self center: preferredPosition.
self bounds: (self bounds translatedToBeWithin: world bounds).
self openInWorld: world.
hand keyboardFocus in: [:priorKeyboardFocus |
hand mouseFocus in: [:priorMouseFocus |
self exclusive ifTrue: [hand newMouseFocus: self].
hand newKeyboardFocus: self.
[self isInWorld] whileTrue:[world doOneSubCycle].
hand newKeyboardFocus: priorKeyboardFocus.
self exclusive ifTrue: [
hand newMouseFocus: priorMouseFocus]]].
^ result!
Eliot Miranda uploaded a new version of MorphicExtras to project The Trunk:
http://source.squeak.org/trunk/MorphicExtras-eem.179.mcz
==================== Summary ====================
Name: MorphicExtras-eem.179
Author: eem
Time: 3 August 2016, 7:42:04.74973 pm
UUID: 7e0dd147-e862-4ad7-9218-8de41bb8b81b
Ancestors: MorphicExtras-tfel.178
Use allInsyancesDo: instead of someInstance/nextInstance to remove grab commands from MorphExtensions.
P.S. to improve start-up time we might consider moving these to snapshot time, if at all possible.
=============== Diff against MorphicExtras-tfel.178 ===============
Item was removed:
- ----- Method: CommandHistory class>>forgetAllGrabCommandsFrom: (in category 'system startup') -----
- forgetAllGrabCommandsFrom: starterInstance
- "Forget all the commands that might be held on to in the properties dicitonary of various morphs for various reasons."
-
- | object |
- object := starterInstance.
- [
- [nil == object] whileFalse: [
- object removeProperty: #undoGrabCommand.
- object := object nextInstance].
- ] ifError: [:err :rcvr | "object is obsolete"
- self forgetAllGrabCommandsFrom: object nextInstance].
-
- "CommandHistory forgetAllGrabCommandsFrom: MorphExtension someInstance"
- !
Item was changed:
----- Method: CommandHistory class>>resetAllHistory (in category 'system startup') -----
resetAllHistory
"Reset all command histories, and make all morphs that might be holding on to undo-grab-commands forget them"
self allInstancesDo: [:c | c resetCommandHistory].
MorphExtension withAllSubclassesDo:
+ [:morphExtensionClass|
+ morphExtensionClass allInstancesDo:
+ [:object| object removeProperty: #undoGrabCommand]]
- [:mexc|
- self forgetAllGrabCommandsFrom: mexc someInstance]
"CommandHistory resetAllHistory"
!
Changes to Trunk (http://source.squeak.org/trunk.html) in the last 24 hours:
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068410.html
Name: Morphic-mt.1225
Ancestors: Morphic-mt.1224
Fixes scratch-pad to be compatible with UI themes. This is not the optimal solution but it works for now.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068411.html
Name: HelpSystem-Core-mt.88
Ancestors: HelpSystem-Core-mt.87
For prospective content authors in our help system, avoid changing protected texts by accident.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068412.html
Name: Help-Squeak-Project-mt.37
Ancestors: Help-Squeak-Project-mt.36
Protect help texts that are fixed or derived from other strings in the system from editing (and duplicating).
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068413.html
Name: Morphic-mt.1226
Ancestors: Morphic-mt.1225
Fixes retractable scroll bars, which did not work properly of mouseOverForKeyboardFocus was disabled. Note that #hasFocus is ancient and not needed anymore for controlling keyboard focus here. See also #hIsScrollbarNeeded and #vIsScrollbarNeeded and maybe other senders of #hasFocus.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068414.html
Name: Morphic-mt.1227
Ancestors: Morphic-mt.1226
Fixes a small regression where the text cursor did not show up on a simple mouse down when it was invisible due to its blinking animation.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068415.html
Name: ToolBuilder-Morphic-mt.178
Ancestors: ToolBuilder-Morphic-mt.177
For disabled buttons, still draw a border to make them still look like buttons, not like labels.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068416.html
Name: Morphic-mt.1228
Ancestors: Morphic-mt.1227
Some last-minute UI theming fix, which applies to the non-flat look (i.e. using gradients) in progress bars. Implementation is not perfect but consistent with LazyListMorph selections, now.
Note that, in the future, we should untangle the use of #gradientMenu and, maybe, add specific preferences.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068417.html
Name: System-mt.861
Ancestors: System-cmm.860
Provide progress indication when applying a new UI theme. Use 1000-ms updates to not slow-down the process unnecessarily.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068418.html
Name: System-mt.862
Ancestors: System-mt.861
Implements Karl's suggestions for the colors in Monokai and Solarized themes for progress bars. Also improve the non-shadow scenario.
=============================================
http://lists.squeakfoundation.org/pipermail/packages/2016-August/068419.html
Name: Monticello-mt.643
Ancestors: Monticello-mt.642
Fixes the merge button in MC's merge browser.
=============================================
Hi All,
This is something to test on all platforms before push. I've used it on
64-bit linux without problems so far.
Levente
On Mon, 25 Jul 2016, commits(a)source.squeak.org wrote:
> Levente Uzonyi uploaded a new version of Network to project The Inbox:
> http://source.squeak.org/inbox/Network-ul.180.mcz
>
> ==================== Summary ====================
>
> Name: Network-ul.180
> Author: ul
> Time: 25 July 2016, 8:40:01.001452 pm
> UUID: 2f23a55c-fec5-41ac-95bd-6a8c2458be95
> Ancestors: Network-nice.179
>
> Socket changes:
> - fixed the comment of #isOtherEndConnected and #isThisEndConnected
> - do not slice the data (TCP) in the image in #sendData:. Let the VM, the kernel, the hardware deal with that.
> - use #isOtherEndConnected when receiving data, and #isThisEndConnected when sending data instead of #isConnected
> - move away from #milliseconds:since:, since we have a clock that won't roll over
>
> =============== Diff against Network-nice.179 ===============
>
> Item was changed:
> ----- Method: Socket>>closeAndDestroy: (in category 'connection open/close') -----
> closeAndDestroy: timeoutSeconds
> "First, try to close this connection gracefully. If the close attempt fails or times out, abort the connection. In either case, destroy the socket. Do nothing if the socket has already been destroyed (i.e., if its socketHandle is nil)."
>
> + socketHandle ifNil: [ ^self ].
> + self isThisEndConnected ifTrue: [
> + self close. "Close this end." ].
> + (self waitForDisconnectionFor: timeoutSeconds) ifFalse: [
> + "The other end has not closed the connect yet, so we will just abort it."
> + self primSocketAbortConnection: socketHandle ].
> + self destroy!
> - socketHandle ifNotNil: [
> - self isConnected ifTrue: [
> - self close. "close this end"
> - (self waitForDisconnectionFor: timeoutSeconds) ifFalse: [
> - "The other end didn't close so we just abort the connection"
> - self primSocketAbortConnection: socketHandle]].
> - self destroy].
> - !
>
> Item was changed:
> ----- Method: Socket>>discardReceivedData (in category 'receiving') -----
> discardReceivedData
> "Discard any data received up until now, and return the number of bytes discarded."
>
> | buf totalBytesDiscarded |
> buf := String new: 10000.
> totalBytesDiscarded := 0.
> + [self isOtherEndConnected and: [self dataAvailable]] whileTrue: [
> - [self isConnected and: [self dataAvailable]] whileTrue: [
> totalBytesDiscarded :=
> totalBytesDiscarded + (self receiveDataInto: buf)].
> ^ totalBytesDiscarded
> !
>
> Item was changed:
> ----- Method: Socket>>isOtherEndConnected (in category 'queries') -----
> isOtherEndConnected
> + "Return true if this socket is connected, or this end has closed the connection but not the other end, so we can still receive data."
> - "Return true if this socket is connected, or this end has closed the connection but not the other end, so we can still send data."
>
> | state |
> socketHandle ifNil: [ ^false ].
> (state := self primSocketConnectionStatus: socketHandle) == Connected ifTrue: [ ^true ].
> ^state == ThisEndClosed
> !
>
> Item was changed:
> ----- Method: Socket>>isThisEndConnected (in category 'queries') -----
> isThisEndConnected
> + "Return true if this socket is connected, other the other end has closed the connection but not this end, so we can still send data."
> - "Return true if this socket is connected, other the other end has closed the connection but not this end, so we can still receive data."
>
> | state |
> socketHandle ifNil: [ ^false ].
> (state := self primSocketConnectionStatus: socketHandle) == Connected ifTrue: [ ^true ].
> ^state == OtherEndClosed
> !
>
> Item was changed:
> ----- Method: Socket>>sendData: (in category 'sending') -----
> sendData: aStringOrByteArray
> "Send all of the data in the given array, even if it requires multiple calls to send it all. Return the number of bytes sent."
>
> "An experimental version use on slow lines: Longer timeout and smaller writes to try to avoid spurious timeouts."
>
> | bytesSent bytesToSend count |
> bytesToSend := aStringOrByteArray size.
> bytesSent := 0.
> [bytesSent < bytesToSend] whileTrue: [
> (self waitForSendDoneFor: 60)
> ifFalse: [ConnectionTimedOut signal: 'send data timeout; data not sent'].
> count := self primSocket: socketHandle
> sendData: aStringOrByteArray
> startIndex: bytesSent + 1
> + count: bytesToSend - bytesSent.
> - count: (bytesToSend - bytesSent min: DefaultSendBufferSize).
> bytesSent := bytesSent + count].
>
> ^ bytesSent
> !
>
> Item was changed:
> ----- Method: Socket>>waitForConnectionFor:ifTimedOut:ifRefused: (in category 'waiting') -----
> waitForConnectionFor: timeout ifTimedOut: timeoutBlock ifRefused: refusedBlock
> "Wait up until the given deadline for a connection to be established. Return true if it is established by the deadline, false if not."
>
> + | deadline timeLeft status |
> + deadline := Time millisecondClockValue + (timeout * 1000) truncated.
> + (status := self primSocketConnectionStatus: socketHandle) == Connected ifTrue: [^true].
> + [ (status == WaitingForConnection) and: [ (timeLeft := deadline - Time millisecondClockValue) > 0 ] ]
> - | startTime msecsDelta msecsEllapsed status |
> - startTime := Time millisecondClockValue.
> - msecsDelta := (timeout * 1000) truncated.
> - status := self primSocketConnectionStatus: socketHandle.
> - status = Connected ifTrue: [^true].
> - [(status = WaitingForConnection) and: [(msecsEllapsed := Time millisecondsSince: startTime) < msecsDelta]]
> whileTrue: [
> + semaphore waitTimeoutMSecs: timeLeft.
> + status := self primSocketConnectionStatus: socketHandle ].
> + status == Connected ifTrue: [ ^true ].
> + status == WaitingForConnection
> + ifTrue: [ timeoutBlock value ]
> + ifFalse: [ refusedBlock value ].
> + ^false!
> - semaphore waitTimeoutMSecs: msecsDelta - msecsEllapsed.
> - status := self primSocketConnectionStatus: socketHandle].
> - status = Connected
> - ifFalse: [
> - status = WaitingForConnection
> - ifTrue: [timeoutBlock value]
> - ifFalse: [refusedBlock value].
> - ^false].
> - ^ true!
>
> Item was changed:
> ----- Method: Socket>>waitForConnectionUntil: (in category 'waiting') -----
> waitForConnectionUntil: deadline
> "Wait up until the given deadline for a connection to be established. Return true if it is established by the deadline, false if not."
>
> + | status timeLeft |
> - | status waitTime |
> [
> (status := self primSocketConnectionStatus: socketHandle) == Connected ifTrue: [ ^true ].
> status == WaitingForConnection ifFalse: [ ^false ].
> + (timeLeft := deadline - Time millisecondClockValue) <= 0 ifTrue: [ ^false ].
> + semaphore waitTimeoutMSecs: timeLeft ] repeat!
> - (waitTime := deadline - Time millisecondClockValue) > 0 ifFalse: [ ^false ].
> - semaphore waitTimeoutMSecs: waitTime ] repeat!
>
> Item was changed:
> ----- Method: Socket>>waitForDataFor:ifClosed:ifTimedOut: (in category 'waiting') -----
> waitForDataFor: timeout ifClosed: closedBlock ifTimedOut: timedOutBlock
> "Wait for the given nr of seconds for data to arrive."
>
> + | deadline timeLeft |
> - | startTime msecsDelta |
> socketHandle ifNil: [ ^closedBlock value ].
> + deadline := Time millisecondClockValue + (timeout * 1000) truncated.
> - startTime := Time millisecondClockValue.
> - msecsDelta := (timeout * 1000) truncated.
> [
> (self primSocketReceiveDataAvailable: socketHandle) ifTrue: [ ^self ].
> + self isOtherEndConnected ifFalse: [ ^closedBlock value ].
> + (timeLeft := deadline - Time millisecondClockValue) <= 0 ifTrue: [ ^timedOutBlock value ].
> - self isConnected ifFalse: [ ^closedBlock value ].
> - (Time millisecondsSince: startTime) < msecsDelta ifFalse: [ ^timedOutBlock value ].
> "Providing a maximum for the time for waiting is a workaround for a VM bug which causes sockets waiting for data forever in some rare cases, because the semaphore doesn't get signaled. Remove the ""min: self class maximumReadSemaphoreWaitTimeout"" part when the bug is fixed."
> readSemaphore waitTimeoutMSecs:
> + (timeLeft min: self class maximumReadSemaphoreWaitTimeout) ] repeat!
> - (msecsDelta - (Time millisecondsSince: startTime) min: self class maximumReadSemaphoreWaitTimeout) ] repeat!
>
> Item was changed:
> ----- Method: Socket>>waitForDataIfClosed: (in category 'waiting') -----
> waitForDataIfClosed: closedBlock
> "Wait indefinitely for data to arrive. This method will block until
> data is available or the socket is closed."
>
> socketHandle ifNil: [ ^closedBlock value ].
> [
> (self primSocketReceiveDataAvailable: socketHandle) ifTrue: [ ^self ].
> + self isOtherEndConnected ifFalse: [ ^closedBlock value ].
> - self isConnected ifFalse: [ ^closedBlock value ].
> "ul 8/13/2014 21:16
> Providing a maximum for the time for waiting is a workaround for a VM bug which
> causes sockets waiting for data forever in some rare cases, because the semaphore
> doesn't get signaled. Replace the ""waitTimeoutMSecs: self class maximumReadSemaphoreWaitTimeout""
> part with ""wait"" when the bug is fixed."
> readSemaphore waitTimeoutMSecs: self class maximumReadSemaphoreWaitTimeout ] repeat!
>
> Item was changed:
> ----- Method: Socket>>waitForDisconnectionFor: (in category 'waiting') -----
> waitForDisconnectionFor: timeout
> "Wait for the given nr of seconds for the connection to be broken.
> Return true if it is broken by the deadline, false if not.
> The client should know the connection is really going to be closed
> (e.g., because he has called 'close' to send a close request to the other end)
> before calling this method."
>
> + | deadline |
> + deadline := Time millisecondClockValue + (timeout * 1000) truncated.
> + [ self isOtherEndConnected and: [ deadline - Time millisecondClockValue > 0 ] ]
> + whileTrue: [
> + self discardReceivedData.
> + "Providing a maximum for the time for waiting is a workaround for a VM bug which causes sockets waiting for data forever in some rare cases, because the semaphore doesn't get signaled. Remove the ""min: self class maximumReadSemaphoreWaitTimeout"" part when the bug is fixed."
> + readSemaphore waitTimeoutMSecs:
> + (deadline - Time millisecondClockValue min: self class maximumReadSemaphoreWaitTimeout) ].
> + ^self isOtherEndConnected!
> - | startTime msecsDelta status |
> - startTime := Time millisecondClockValue.
> - msecsDelta := (timeout * 1000) truncated.
> - status := self primSocketConnectionStatus: socketHandle.
> - [((status == Connected) or: [(status == ThisEndClosed)]) and:
> - [(Time millisecondsSince: startTime) < msecsDelta]] whileTrue: [
> - self discardReceivedData.
> - "Providing a maximum for the time for waiting is a workaround for a VM bug which causes sockets waiting for data forever in some rare cases, because the semaphore doesn't get signaled. Remove the ""min: self class maximumReadSemaphoreWaitTimeout"" part when the bug is fixed."
> - readSemaphore waitTimeoutMSecs:
> - (msecsDelta - (Time millisecondsSince: startTime) min: self class maximumReadSemaphoreWaitTimeout).
> - status := self primSocketConnectionStatus: socketHandle].
> - ^ status ~= Connected!
>
> Item was changed:
> ----- Method: Socket>>waitForSendDoneFor: (in category 'waiting') -----
> waitForSendDoneFor: timeout
> "Wait up until the given deadline for the current send operation to complete. Return true if it completes by the deadline, false if not."
>
> + | deadline timeleft |
> + deadline := Time millisecondClockValue + (timeout * 1000) truncated.
> - | startTime msecsDelta msecsEllapsed |
> - startTime := Time millisecondClockValue.
> - msecsDelta := (timeout * 1000) truncated.
> [
> (self primSocketSendDone: socketHandle) ifTrue: [ ^true ].
> + self isThisEndConnected ifFalse: [ ^false ].
> + (timeleft := deadline - Time millisecondClockValue) <= 0 ifTrue: [ ^false ].
> + writeSemaphore waitTimeoutMSecs: timeleft ] repeat!
> - self isConnected ifFalse: [ ^false ].
> - (msecsEllapsed := Time millisecondsSince: startTime) < msecsDelta ifFalse: [ ^false ].
> - writeSemaphore waitTimeoutMSecs: msecsDelta - msecsEllapsed ] repeat!
>
>
>
The sub menu indicator arrow is black and menu color is very dark gray so
it is hard to see.
Selection color is used as progress bar indication color. And same color is
used as color for progress bar morph.
Best,
Karl
Marcel Taeumel uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-mt.861.mcz
==================== Summary ====================
Name: System-mt.861
Author: mt
Time: 3 August 2016, 3:48:48.221245 pm
UUID: 74e725aa-ea12-df48-b3cf-730dba8dccc6
Ancestors: System-cmm.860
Provide progress indication when applying a new UI theme. Use 1000-ms updates to not slow-down the process unnecessarily.
=============== Diff against System-cmm.860 ===============
Item was changed:
----- Method: UserInterfaceTheme>>apply (in category 'actions') -----
apply
"Apply this theme to all affected objects. Let classes decide on how to iterate and call their instances."
UserInterfaceTheme current: self.
self class clientClassesToReapply in: [:cc |
cc do: [:eachClass | eachClass applyUserInterfaceTheme].
+ (cc select: [:eachClass | eachClass canApplyThemeToInstances])
+ do: [:eachClass | eachClass applyThemeToInstances]
+ displayingProgress: [:eachClass | 'Applying {1} to instances of {2}' format: {self name. eachClass name}]
+ every: 1000 ].
- cc
- select: [:eachClass | eachClass canApplyThemeToInstances]
- thenDo: [:eachClass | eachClass applyThemeToInstances]].
Project current restoreDisplay.!