silence trashcan?

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

silence trashcan?

Mark Nelson-7
How do I silence the 'camera' sound when items go to the trash bin, while keeping the 'preserve trash' functionality? I thought I had this solved when I found the "TrashCanMorph >> playDeleteSound" message, but this is a 'ping' sound that plays simultaneously along with the 'camera' sound. I successfullly eliminated the 'ping' by commenting it out in "TrashCanMorph >> moveToTrash" but I haven't been able to figure out who's responsible for generating the 'camera' sound. 
Thanks,
--Mark
 
 

_______________________________________________
Squeakland mailing list
[hidden email]
http://squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: silence trashcan?

K. K. Subramaniam
On Wednesday 12 December 2007 8:51 am, Mark Nelson wrote:
> How do I silence the 'camera' sound when items go to the trash bin, while
> keeping the 'preserve trash' functionality? I thought I had this solved
> when I found the "TrashCanMorph >> playDeleteSound" message, but this is a
> 'ping' sound that plays simultaneously along with the 'camera' sound. I
> successfullly eliminated the 'ping' by commenting it out in "TrashCanMorph
In TrashCanMorph>>moveToTrash, you will find two statements that play sounds  
depending on whether preserveTrash is set or not - playSoundNamed: 'scratch'
and playDeleteSound. You can mark the entire first statement as a comment to
exclude sounds. E.g.
        "Preferences soundsEnabled ..... ]]."
and that should do the trick. You could also replace the two play statements
with:
        playSoundNamed: 'silence'

Subbu

_______________________________________________
Squeakland mailing list
[hidden email]
http://squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: silence trashcan?

Scott Wallace
In reply to this post by Mark Nelson-7
Hi, Mark,

What you're hearing is the "page flip sound" made when the Trash  
"Book" is turned to a new page which will accommodate the item just  
added to the trash.

So to silence it, double-click on a trashcan, bring up the Trash's  
"book" menu, choose "sound effect for all pages", and then select  
"silence" as the desired sound.

Arguably it's a bug that a page-flip sound is made in this case, which  
we should fix in short order.  In the meantime, the above procedure  
should bring you the silence you seek.

Cheers,

   -- Scott


PS:  In a current Squeakland image, the Trash's "book" menu can be  
obtained by clicking on the black dot in its header.  In an OLPC-etoys  
image, bring up the halo on the trash tool, and from the halo menu  
choose "book..." to get the trash's "book" menu.  In that book menu,  
click on "visual and sound effects..." and from the resulting submenu  
choose "set sound effect for all pages", and choose "silence" at the  
desired sound effect.


On Dec 11, 2007, at 7:21 PM, Mark Nelson wrote:

> How do I silence the 'camera' sound when items go to the trash bin,  
> while keeping the 'preserve trash' functionality? I thought I had  
> this solved when I found the "TrashCanMorph >> playDeleteSound"  
> message, but this is a 'ping' sound that plays simultaneously along  
> with the 'camera' sound. I successfullly eliminated the 'ping' by  
> commenting it out in "TrashCanMorph >> moveToTrash" but I haven't  
> been able to figure out who's responsible for generating the  
> 'camera' sound.
> Thanks,
> --Mark
>
>
> _______________________________________________
> Squeakland mailing list
> [hidden email]
> http://squeakland.org/mailman/listinfo/squeakland


_______________________________________________
Squeakland mailing list
[hidden email]
http://squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: silence trashcan?

Mark Nelson-7
Hi Scott,
 
Thanks for the tip.  Setting the trash can Book sound effect to "silence" works fine until the trash is emptied. After emptying the trash, I guess a new book gets created, which brings back the default 'camera' sound effect. Where does the default page turn sound get set? I'd like to set it to 'silence' for all Books, but I'm not sure how to do that. I looked at 'initialize' in BookMorph and BooklikeMorph, but didn't see it there.
 
As a workaround, I simply commented out the appropriate line in BooklikeMorph >> playPageFlipSound, so that page turns are always and forever silent. However, this could be problematic if a student creates a book and actually wants to turn sound effects back on.
 
Thanks,
--Mark

On Dec 11, 2007 11:25 PM, Scott Wallace <[hidden email]> wrote:
Hi, Mark,

What you're hearing is the "page flip sound" made when the Trash
"Book" is turned to a new page which will accommodate the item just
added to the trash.

So to silence it, double-click on a trashcan, bring up the Trash's
"book" menu, choose "sound effect for all pages", and then select
"silence" as the desired sound.

Arguably it's a bug that a page-flip sound is made in this case, which
we should fix in short order.  In the meantime, the above procedure
should bring you the silence you seek.

Cheers,

  -- Scott


PS:  In a current Squeakland image, the Trash's "book" menu can be
obtained by clicking on the black dot in its header.  In an OLPC-etoys
image, bring up the halo on the trash tool, and from the halo menu
choose "book..." to get the trash's "book" menu.  In that book menu,
click on "visual and sound effects..." and from the resulting submenu
choose "set sound effect for all pages", and choose "silence" at the
desired sound effect.


On Dec 11, 2007, at 7:21 PM, Mark Nelson wrote:

> How do I silence the 'camera' sound when items go to the trash bin,
> while keeping the 'preserve trash' functionality? I thought I had
> this solved when I found the "TrashCanMorph >> playDeleteSound"
> message, but this is a 'ping' sound that plays simultaneously along
> with the 'camera' sound. I successfullly eliminated the 'ping' by
> commenting it out in "TrashCanMorph >> moveToTrash" but I haven't
> been able to figure out who's responsible for generating the
> 'camera' sound.
> Thanks,
> --Mark
>
>
> _______________________________________________
> Squeakland mailing list
> [hidden email]
> http://squeakland.org/mailman/listinfo/squeakland



_______________________________________________
Squeakland mailing list
[hidden email]
http://squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: silence trashcan?

Karl-19
In reply to this post by Mark Nelson-7
Mark Nelson wrote:
> How do I silence the 'camera' sound when items go to the trash bin,
> while keeping the 'preserve trash' functionality? I thought I had this
> solved when I found the "TrashCanMorph >> playDeleteSound" message,
> but this is a 'ping' sound that plays simultaneously along with the
> 'camera' sound. I successfullly eliminated the 'ping' by commenting it
> out in "TrashCanMorph >> moveToTrash" but I haven't been able to
> figure out who's responsible for generating the 'camera' sound.
> Thanks,
> --Mark
Funny coincidence, I fixed this for OLPC image yesterday.
Try filing in attached change set.
You have to empty the current thrash and close it, then the new instance
will not make camera sound.

Karl

'From Squeakland 3.8-05 of 7 September 2005 [latest update: #552] on 12 December 2007 at 6:32:24 pm'!

!Utilities class methodsFor: 'scraps' stamp: 'kfr 12/12/2007 18:29'!
scrapsBook
        | header aButton label |
        ScrapsBook ifNil:
                [ScrapsBook _ BookMorph new pageSize: 200@300; setNameTo: 'scraps' translated.
                ScrapsBook color: Color yellow muchLighter.
                ScrapsBook borderColor: Color darkGray; borderWidth: 2.
                ScrapsBook setProperty:#transitionSpec toValue: (Array with: 'silence'  with: #none with: #none).
                ScrapsBook removeEverything; showPageControls; insertPage.
                header _ AlignmentMorph newRow wrapCentering: #center; cellPositioning: #leftCenter.
                header setProperty: #header toValue: true.
                header addMorph: (aButton _ SimpleButtonMorph new label: 'O' font: Preferences standardButtonFont).
                aButton target: ScrapsBook; color:  Color tan; actionSelector: #delete;
                                setBalloonText: 'Close the trashcan.
(to view again later, click on any trashcan).' translated.

                header addMorphBack: AlignmentMorph newVariableTransparentSpacer beSticky.
                header addMorphBack: (label _ UpdatingStringMorph new target: self) beSticky.
                label getSelector: #trashTitle; useStringFormat; step.
                header addMorphBack: AlignmentMorph newVariableTransparentSpacer beSticky.
                header addMorphBack: (aButton _ SimpleButtonMorph new label: 'E' translated font: Preferences standardButtonFont).
                aButton target: Utilities; color:  Color veryLightGray; actionSelector: #maybeEmptyTrash;
                                setBalloonText: 'Click here to empty the trash.' translated.
                ScrapsBook currentPage addMorph: (TextMorph new contents: 'Objects you drag into the trash will automatically be saved here, one object per page, in case you need them later.  To disable this feature set the "preserveTrash" Preference to false.

You can individually expunge objects by hitting the - control, and you can empty out all the objects in the trash can by hitting the "E" button at top right.' translated
                        wrappedTo: 190).

                ScrapsBook addMorphFront: header.
                ScrapsBook setProperty: #scraps toValue: true].
        ^ ScrapsBook

        "Utilities emptyScrapsBook"
! !


_______________________________________________
Squeakland mailing list
[hidden email]
http://squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: silence trashcan?

K. K. Subramaniam
On Wednesday 12 December 2007 11:05 pm, Karl wrote:
> header addMorphBack: (aButton _ SimpleButtonMorph new label: 'E' translated
> font: Preferences standardButtonFont).
Karl,

Just curious. 'E' is used as a button icon. Does it make sense to request a
translation for it? Is the expectation that the translator would subsitute a
suitable letter to mean "to Empty"?

Subbu

_______________________________________________
Squeakland mailing list
[hidden email]
http://squeakland.org/mailman/listinfo/squeakland
Reply | Threaded
Open this post in threaded view
|

Re: silence trashcan?

Karl-19
subbukk wrote:

> On Wednesday 12 December 2007 11:05 pm, Karl wrote:
>  
>> header addMorphBack: (aButton _ SimpleButtonMorph new label: 'E' translated
>> font: Preferences standardButtonFont).
>>    
> Karl,
>
> Just curious. 'E' is used as a button icon. Does it make sense to request a
> translation for it? Is the expectation that the translator would subsitute a
> suitable letter to mean "to Empty"?
>
> Subbu
In the fix I suggest to the OLPC image I changed the label to 'EMPTY'
which I think make it more clear what the button do.

Karl

_______________________________________________
Squeakland mailing list
[hidden email]
http://squeakland.org/mailman/listinfo/squeakland