Ви не можете вибрати більше 25 тем Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. var PanelToggler = require("../side_pannels/SidePanelToggler");
  2. var buttonHandlers = {
  3. "bottom_toolbar_contact_list": function () {
  4. BottomToolbar.toggleContactList();
  5. },
  6. "bottom_toolbar_film_strip": function () {
  7. BottomToolbar.toggleFilmStrip();
  8. },
  9. "bottom_toolbar_chat": function () {
  10. BottomToolbar.toggleChat();
  11. }
  12. };
  13. var BottomToolbar = (function (my) {
  14. my.init = function () {
  15. for(var k in buttonHandlers)
  16. $("#" + k).click(buttonHandlers[k]);
  17. };
  18. my.toggleChat = function() {
  19. PanelToggler.toggleChat();
  20. };
  21. my.toggleContactList = function() {
  22. PanelToggler.toggleContactList();
  23. };
  24. my.toggleFilmStrip = function() {
  25. var filmstrip = $("#remoteVideos");
  26. filmstrip.toggleClass("hidden");
  27. };
  28. $(document).bind("remotevideo.resized", function (event, width, height) {
  29. var bottom = (height - $('#bottomToolbar').outerHeight())/2 + 18;
  30. $('#bottomToolbar').css({bottom: bottom + 'px'});
  31. });
  32. return my;
  33. }(BottomToolbar || {}));
  34. module.exports = BottomToolbar;