Forked mumble-django project from https://bitbucket.org/Svedrin/mumble-django
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

78 lines
2.7 KiB

  1. // kate: space-indent on; indent-width 4; replace-tabs on;
  2. function render_mumble( divname, urls ){
  3. var mainpanel = new Ext.Panel({
  4. renderTo: divname,
  5. height: 600,
  6. layout: "border",
  7. items: [{
  8. xtype: "mumblechannelviewer",
  9. region: "west",
  10. width: 350,
  11. split: true,
  12. source_url: urls.data,
  13. }, {
  14. xtype: "tabpanel",
  15. region: "center",
  16. activeTab: 0,
  17. items: [{
  18. title: gettext("Registration"),
  19. xtype: "form",
  20. items: [{
  21. name: "username",
  22. fieldLabel: gettext("User name"),
  23. xtype: "textfield",
  24. }, {
  25. name: "password",
  26. fieldLabel: gettext("Password"),
  27. xtype: "textfield",
  28. inputType: "password",
  29. }],
  30. }, {
  31. title: gettext("Administration"),
  32. xtype: "form",
  33. items: [{
  34. name: "test",
  35. fieldLabel: "testing",
  36. xtype: "textfield",
  37. }],
  38. }, {
  39. title: gettext("User texture"),
  40. layout: "border",
  41. items: [{
  42. region: "north",
  43. layout: "hbox",
  44. height: 220,
  45. items: [{
  46. flex: 1,
  47. height: 200,
  48. title: gettext("Texture"),
  49. html: String.format('<img src="{0}" alt="Avatar" />', urls.myavatar),
  50. }, {
  51. flex: 1,
  52. height: 200,
  53. title: gettext("Gravatar"),
  54. html: String.format('<img src="{0}" alt="grAvatar" />', urls.gravatar),
  55. }],
  56. }, {
  57. region: "center",
  58. xtype: "form",
  59. items: [{
  60. name: "usegravatar",
  61. fieldLabel: gettext("Use Gravatar"),
  62. xtype: "checkbox",
  63. }, {
  64. name: "uploadpic",
  65. fieldLabel: gettext("Upload Avatar"),
  66. xtype: "textfield",
  67. inputType: "file",
  68. }],
  69. }],
  70. }, {
  71. xtype: "userEditorPanel",
  72. django_users_url: urls.django_users,
  73. mumble_users_url: urls.mumble_users,
  74. } ],
  75. }],
  76. });
  77. }