This is a read-only archive of the old Scratch 1.x Forums.
Try searching the current Scratch discussion forums.

#1 2012-05-27 04:54:24

williambl
Scratcher
Registered: 2011-04-08
Posts: 100+

Help - I need a bit of code I accidentally removed.

I accidentally removed a bit of code. Go to Scratch-UI-Panes --> ScratchFrameMorph --> instance --> menu/button actions --> shareMenu: and copy all the code here please so that I can get it back.


http://internetometer.com/imagesmall/34650.png
http://www.danasoft.com/sig/Epicnesssign.jpg

Offline

 

#2 2012-05-27 05:05:29

Hardmath123
Scratcher
Registered: 2010-02-19
Posts: 1000+

Re: Help - I need a bit of code I accidentally removed.

Code:

shareMenu: t1 
    | t2 |
    t2 _ CustomMenu new.
    t2 add: 'Share This Project Online' action: #share.
    t2 add: 'Go To Scratch Website' action: #launchScratchWebsite.
    Sensor shiftPressed ifTrue: [self addServerCommandsTo: t2].
    t2 localize.
    #(1 2 ) do: [:t3 | t2 labels at: t3 put: ((t2 labels at: t3)
                copyFrom: 1 to: (t2 labels at: t3) size - 1)
                , ScratchTranslator ellipsesSuffix].
    t2 invokeOn: self at: t1 bottomLeft + (0 @ 10)

smile


Hardmaths-MacBook-Pro:~ Hardmath$ sudo make $(whoami) a sandwich

Offline

 

#3 2012-05-27 06:21:22

williambl
Scratcher
Registered: 2011-04-08
Posts: 100+

Re: Help - I need a bit of code I accidentally removed.

Hardmath123 wrote:

Code:

shareMenu: t1 
    | t2 |
    t2 _ CustomMenu new.
    t2 add: 'Share This Project Online' action: #share.
    t2 add: 'Go To Scratch Website' action: #launchScratchWebsite.
    Sensor shiftPressed ifTrue: [self addServerCommandsTo: t2].
    t2 localize.
    #(1 2 ) do: [:t3 | t2 labels at: t3 put: ((t2 labels at: t3)
                copyFrom: 1 to: (t2 labels at: t3) size - 1)
                , ScratchTranslator ellipsesSuffix].
    t2 invokeOn: self at: t1 bottomLeft + (0 @ 10)

smile

thanks.


http://internetometer.com/imagesmall/34650.png
http://www.danasoft.com/sig/Epicnesssign.jpg

Offline

 

#4 2012-05-27 07:56:00

Paddle2See
Scratch Team
Registered: 2007-10-27
Posts: 1000+

Re: Help - I need a bit of code I accidentally removed.

Closed by request of the topic owner.


http://i39.tinypic.com/2nav6o7.gif

Offline

 

Board footer