Customize play/pause and mute unmute buttons

1,267 views
Skip to first unread message

rahuu

unread,
Sep 20, 2014, 5:35:03 PM9/20/14
to gwd...@googlegroups.com
I"m trying to make a play/pause button using a graphic and TapArea component. In previous versions of GWD it was pretty easy to get the video to play after it was paused (like toggle mute event). I assumed that creating a play after pause event would make it work again. Any ideas on a workaround? 

Also, I would like to know if there's a way to get a mute/unmute button to toggle graphics. The the audio mutes and unmutes properly but I;m stumped on hoe to switch the graphics.

I hope that makes sense.

mati...@gmail.com

unread,
Feb 12, 2017, 4:08:12 AM2/12/17
to Google Web Designer beta
Hi Rahuu: I was trying to do the same thing, and found the way to do it! I´ll try to explain the way I used... sorry for my english. First of all I use two images of the same size, one with a PUASE icon and another one with a PLAY icon, both png files. I seted the visibility of the Play button to "Hidden", and the pause button to "Visible", I want to see the pause button first because I´m using it for stopping an autoplayed audio.
So, then it´s all about events. When I click the pause button, with CSS style event, set the "Visibility" of your pause button to "Hidden" and your play button to "Visible", and of course add an event for mute toggle the audio in both buttons. Hope it works for you! Best regards.

james f

unread,
Feb 15, 2017, 12:36:38 PM2/15/17
to Google Web Designer beta
Good idea! Can you share the code for those events to PLAY and PAUSE?

San Khong

unread,
Feb 15, 2017, 12:57:12 PM2/15/17
to Google Web Designer beta
Hi James,

Please see this post. I attached a sample file there with the events for the customize video control buttons.

Hope it helps.
San
Google Web Designer team
Reply all
Reply to author
Forward
Message has been deleted
0 new messages