[Vm-dev] Add shortcut button on FileChooser dialog of Scratch 1.4

Gustavo Duarte gus.duarte at gmail.com
Mon Mar 24 21:35:50 UTC 2014


Hi Tim,

Thanks for confirm my guessing, I'll follow this approach.


Regards.

On 03/24/2014 01:55 PM, tim Rowledge wrote:
>
> vm-dev probably isn’t the best possible place to discuss Scratch code changes, but since we’re here -
>
> you’ve got the basic idea ok. You just need to actually implement the #usb method (using your example below). Take a look at implementors of #myComp, #myHome, #scratchBackgrounds etc. for inspiration.
>
> On 24-03-2014, at 8:39 AM, Gustavo Duarte <gus.duarte at gmail.com> wrote:
>
>> Hi folks,
>>
>> I would like add a USB shortcut button on "Project Save As" File Chooser Dialog of Scratch 1.4 on Gnome.
>>
>> I'm looking for a similar behavior that Scratch has on Sugar.
>>
>> Currently File Chooser dialogue has myComputer, Home, Project directory short cuts,  I want add another one shortcut for USB.
>>
>> I guess that I should modify
>>
>> ScratchFileChooserDialog.addShortcutButtons method, but i'm not sure how.
>>
>> I think the change needed could be like something that:
>>
>> shortcutColumn addMorphBack: ( self shortcutButtonLabel: 	
>>                                self labelForUsbFolder
>>                                action: #usb
>>                                icon #folderUsb),
>>
>> So, beside that, I have to add a kind of handler to the action, right ? How can I do that ?
>>
>>
>> Sorry if this kind of question isn't fit to this foro.
>>
>> Thanks in advance.
>>
>> Gustavo.
>>
>
>
> tim
> --
> tim Rowledge; tim at rowledge.org; http://www.rowledge.org/tim
> Strange OpCodes: RBR: Remove Bits Randomly
>
>


More information about the Vm-dev mailing list