Package com.sun.lwuit

Examples of com.sun.lwuit.Container.addComponent()


       
        String temp = (String)chat.jids.elementAt(j);
        if (temp.equals(currentConversation.name))
          continue;
        else if (temp.indexOf('@') != -1)
          friends.addComponent(new Label(temp.substring(0, temp.indexOf('@'))));
        else
          friends.addComponent(new Label(temp));
      }
      multi.addComponent(BorderLayout.CENTER, friends);
      //conversationForm.append(new util.CustomSpacer(conversationForm.getWidth()));
View Full Code Here


        if (temp.equals(currentConversation.name))
          continue;
        else if (temp.indexOf('@') != -1)
          friends.addComponent(new Label(temp.substring(0, temp.indexOf('@'))));
        else
          friends.addComponent(new Label(temp));
      }
      multi.addComponent(BorderLayout.CENTER, friends);
      //conversationForm.append(new util.CustomSpacer(conversationForm.getWidth()));
      TextField tf1 = new TextField(Contents.invite_textbox, 64);
     
View Full Code Here

      }*/
      text.getStyle().setBorder(Border.createEmpty());
          Label txt = new Label(m.substring(0, m.indexOf(">")+1));
          txt.getStyle().setFgColor(0xF1F57C);
          txt.getStyle().setBgTransparency(0);
          text.addComponent(txt);
          m = m.substring(m.indexOf(">")+1, m.length());
          if ((p = m.indexOf("1smile")) != -1) { //check smiles
          //  conversationForm.addComponent(txt);
            if (p > 0) {
              text.setLayout(new BoxLayout(BoxLayout.Y_AXIS));
View Full Code Here

          m = m.substring(m.indexOf(">")+1, m.length());
          if ((p = m.indexOf("1smile")) != -1) { //check smiles
          //  conversationForm.addComponent(txt);
            if (p > 0) {
              text.setLayout(new BoxLayout(BoxLayout.Y_AXIS));
              text.addComponent(new MyTextArea(m.substring(0, p),0,p));
            }
            Label l = new Label(Contents.displayImage(m.substring(p, p + 7)));
            l.getStyle().setBgTransparency(0);
            text.addComponent( l);
            if (p + 8 < m.length()-1)
View Full Code Here

              text.setLayout(new BoxLayout(BoxLayout.Y_AXIS));
              text.addComponent(new MyTextArea(m.substring(0, p),0,p));
            }
            Label l = new Label(Contents.displayImage(m.substring(p, p + 7)));
            l.getStyle().setBgTransparency(0);
            text.addComponent( l);
            if (p + 8 < m.length()-1)
              text.addComponent(new MyTextArea(m.substring(p + 8, m.length()),0,(m.length()-(p+8))));
         
          }
          if ((j = m.indexOf("+url+")) != -1) { //check links
View Full Code Here

            }
            Label l = new Label(Contents.displayImage(m.substring(p, p + 7)));
            l.getStyle().setBgTransparency(0);
            text.addComponent( l);
            if (p + 8 < m.length()-1)
              text.addComponent(new MyTextArea(m.substring(p + 8, m.length()),0,(m.length()-(p+8))));
         
          }
          if ((j = m.indexOf("+url+")) != -1) { //check links
            //conversationForm.addComponent(txt);
            //String name_link = "link";
View Full Code Here

                }*/
            text.setLayout(new BoxLayout(BoxLayout.Y_AXIS));
            int k = m.indexOf("-url-");
            if (j > 0) {
              text.setLayout(new BoxLayout(BoxLayout.Y_AXIS));
              text.addComponent(new MyTextArea(m.substring(0, j), 0,j));
            }
            j = j + 5;
            Button link = new Button(m.substring(j, k));
            link.getStyle().setBgTransparency(100);
            link.getStyle().setBorder(Border.createEmpty()); //no border
View Full Code Here

            j = j + 5;
            Button link = new Button(m.substring(j, k));
            link.getStyle().setBgTransparency(100);
            link.getStyle().setBorder(Border.createEmpty()); //no border
            link.addActionListener(new ButtonActionListener());
            text.addComponent(link); k = k + 5;
            if (k < m.length()-1)
              text.addComponent(new MyTextArea(m.substring(k, m.length()), 0, 100));
         

          }
View Full Code Here

            link.getStyle().setBgTransparency(100);
            link.getStyle().setBorder(Border.createEmpty()); //no border
            link.addActionListener(new ButtonActionListener());
            text.addComponent(link); k = k + 5;
            if (k < m.length()-1)
              text.addComponent(new MyTextArea(m.substring(k, m.length()), 0, 100));
         

          }
          else if (j == -1 && p == -1) {
            //txt.setText(m);
View Full Code Here

          }
          else if (j == -1 && p == -1) {
            //txt.setText(m);
            MyTextArea t = new MyTextArea(m, 0,50);
            t.setEnabled(true);
            text.addComponent(t);
          }
               
          conversationForm.addComponent(text);
        }
       
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.