~ubuntu-branches/ubuntu/lucid/jwchat/lucid

« back to all changes in this revision

Viewing changes to subscription.html.vi_VN

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2008-08-24 15:02:53 UTC
  • mfrom: (3.1.4 intrepid)
  • Revision ID: james.westby@ubuntu.com-20080824150253-h0z39rzjmo4lc1k5
Tags: 1.0beta3-3
* Clean up README.Debian. (Closes: #481320)
* Add brazilian debconf messages translation. (Closes: #481522)
* Add swedish debconf messages translation. (Closes: #494887)
* Add italian debconf messages translation. (Closes: #495780)
* Add russian debconf messages translation. (Closes: #495573)
* Add finnish debconf messages translation. (Closes: #496227)

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
    <script src="shared.js"></script>
7
7
    <script src="switchStyle.js"></script>
8
8
    <script src="xmlextras.js"></script>
9
 
    <script src="JSJaCPacket.js"></script>
 
9
    <script src="jsjac.js"></script>
10
10
    <script language="JavaScript1.2">
11
11
      <!--
12
12
var jid;
13
13
var srcW; // the source window with necessary data
14
14
 
15
15
function sendSub() {
16
 
        var aPresence = new JSJaCPresence();
17
 
        aPresence.setType('subscribe');
 
16
  var aPresence = new JSJaCPresence();
 
17
  aPresence.setType('subscribe');
18
18
  
19
19
  if (!document.forms[0].to.value || document.forms[0].to.value == '') {
20
20
    alert("JID missing");
28
28
 
29
29
  aPresence.setTo(to);
30
30
  if (document.forms[0].msg.value && document.forms[0].msg.value != '')
31
 
                aPresence.setStatus(document.forms[0].msg.value);
 
31
    aPresence.setStatus(document.forms[0].msg.value);
32
32
 
33
 
  srcW.con.syncSend(aPresence);
 
33
  srcW.con.send(aPresence);
34
34
    
35
35
  window.close();
36
36
}
37
37
 
38
38
function selectService(selbox) {
39
 
        var el = selbox.options[selbox.selectedIndex];
40
 
        var to = document.forms[0].elements['to'];
41
 
        // cut off node
42
 
        var i = to.value.indexOf('@');
43
 
        if (i != -1)
44
 
                to.value = to.value.substring(0,i);
45
 
        if (el.value != '')
46
 
                to.value += "@" + el.value;
 
39
  var el = selbox.options[selbox.selectedIndex];
 
40
  var to = document.forms[0].elements['to'];
 
41
  // cut off node
 
42
  var i = to.value.indexOf('@');
 
43
  if (i != -1)
 
44
    to.value = to.value.substring(0,i);
 
45
  if (el.value != '')
 
46
    to.value += "@" + el.value;
47
47
}
48
48
 
49
49
function init() {
60
60
  document.title += (jid)?" to " + jid:"";
61
61
  if (jid)
62
62
    document.forms[0].to.value = jid;
63
 
 
64
 
        /* detect services */
 
63
  
 
64
  /* detect services */
65
65
        
66
 
        var services = document.forms[0].elements["services"];
67
 
        var optidx=1;
68
 
        for (var i in srcW.disco) {
69
 
                if (srcW.disco[i].getNode().getElementsByTagName('identity').item(0)) {
70
 
                        var item = srcW.disco[i].getNode().getElementsByTagName('identity').item(0);
71
 
                        if (item.getAttribute('category') == 'gateway')
72
 
                                services.options[optidx++] = new Option(item.getAttribute('name'),srcW.disco[i].getFrom());
73
 
                }
74
 
        }
 
66
  var services = document.forms[0].elements["services"];
 
67
  var optidx=1;
 
68
  for (var i in srcW.disco) {
 
69
    if (!srcW.disco[i].getNode) continue;
 
70
    if (srcW.disco[i].getNode().getElementsByTagName('identity').item(0)) {
 
71
      var item = srcW.disco[i].getNode().getElementsByTagName('identity').item(0);
 
72
      if (item.getAttribute('category') == 'gateway')
 
73
        services.options[optidx++] = new Option(item.getAttribute('name'),srcW.disco[i].getFrom());
 
74
    }
 
75
  }
75
76
 
76
77
}
77
78
                
96
97
  </head>
97
98
  <body style="margin:8px">
98
99
    <form name="sub" style="border:0;padding:0;margin:0;" onSubmit="return sendSub();">
99
 
      <table border=0 width="100%" height="100%">
100
 
                                        <tr><td nowrap>Search for a User:</td><td><button onClick="return srcW.openSearch();">Open Search</button></td></tr>
 
100
      <table border="0" width="100%" height="100%">
 
101
          <tr><td nowrap>Search for a User:</td><td><button onClick="return srcW.openSearch();">Open Search</button></td></tr>
101
102
          <tr><td colspan=2><hr noshade size="1" size="100%"></td></tr>
102
103
          <tr>
103
 
            <td align='right' nowrap><label for="to">Send subscription to</label></td>
104
 
                                                <td width="100%"><input type="text" id="to" name="to" size="1" style="width:100%;" tabindex=1></td>
105
 
                                        </tr>
106
 
                                        <tr>
107
 
                                                <td nowrap align="right"><label for="services">Service (optional)</label></td>
108
 
                                                <td width="100%">
109
 
                                                        <select name="services" id="services" onChange="selectService(this);" tabindex=2><option value=''>local jabber user</option></select>
110
 
                                                </td>
111
 
                                        </tr>
 
104
            <td align="right" nowrap><label for="to">Send subscription to</label></td>
 
105
            <td width="100%"><input type="text" id="to" name="to" size="1" style="width:100%;" tabindex="1"></td>
 
106
          </tr>
 
107
          <tr>
 
108
            <td nowrap align="right"><label for="services">Service (optional)</label></td>
 
109
            <td width="100%">
 
110
              <select name="services" id="services" onChange="selectService(this);" tabindex="2"><option value="">local jabber user</option></select>
 
111
            </td>
 
112
          </tr>
112
113
          <tr height="100%">
113
 
                                                <td colspan=2>
114
 
                                                        <textarea id="msg" wrap="physical" class="msgBox" tabindex=3>I would like to add you to my roster.</textarea>
115
 
                                                </td>
116
 
                                        </tr>
117
 
          <tr><td colspan=2><hr noshade size="1" size="100%"></td></tr>
 
114
            <td colspan=2>
 
115
              <textarea id="msg" wrap="physical" class="msgBox" tabindex="3">I would like to add you to my roster.</textarea>
 
116
            </td>
 
117
          </tr>
 
118
          <tr><td colspan="2"><hr noshade size="1" size="100%"></td></tr>
118
119
          <tr>
119
 
                                                <td colspan=2 align="right">
120
 
                                                        <button onClick="window.close();" tabindex=5>Cancel</button>&nbsp;<button type="submit" tabindex=4>Send</button>
121
 
                                                </td>
122
 
                                        </tr>
 
120
            <td colspan="2" align="right">
 
121
              <button type="button" onClick="window.close();" tabindex="5">Cancel</button>&nbsp;<button type="submit" tabindex="4">Send</button>
 
122
            </td>
 
123
          </tr>
123
124
      </table>
124
125
    </form>
125
126
  </body>