예제 #1
0
 public VirtualContactList() {
   super("");
   RosterContent rc = new RosterContent(this);
   rc.setModel(rc.getUpdater().createModel());
   content = rc;
   // #sijapp cond.if modules_TOUCH is "true"#
   softBar = new RosterToolBar();
   // #sijapp cond.end #
   softBar.setSoftBarLabels("menu", "context_menu", "context_menu", false);
   updateOption();
 }
예제 #2
0
 // #sijapp cond.if modules_TOUCH is "true"#
 protected void stylusXMoved(TouchState state) {
   if (getWidth() / 2 < Math.abs(state.fromX - state.x)) {
     boolean isTrue = state.fromX < state.x;
     int currentModel = 0;
     if (Options.getBoolean(Options.OPTION_CL_HIDE_OFFLINE)) currentModel = 1;
     if (((RosterContent) content).getModel() == getUpdater().getChatModel()) currentModel = 2;
     currentModel = (currentModel + 3 + (isTrue ? -1 : +1)) % 3;
     switch (currentModel) {
       case 0:
         Options.setBoolean(Options.OPTION_CL_HIDE_OFFLINE, false);
         updateOfflineStatus();
         Options.safeSave();
         break;
       case 1:
         Options.setBoolean(Options.OPTION_CL_HIDE_OFFLINE, true);
         updateOfflineStatus();
         Options.safeSave();
         break;
       case 2:
         ((RosterContent) content).setModel(getUpdater().getChatModel());
         break;
     }
     updateTitle();
     Jimm.getJimm().getCL().activate();
   }
 }
예제 #3
0
 public final void update() {
   ((RosterContent) content).update();
 }
예제 #4
0
 protected void restoring() {
   content.setTopByOffset(content.getTopOffset());
   ((RosterContent) content).update();
 }
예제 #5
0
 public void updateOfflineStatus() {
   getUpdater().getModel().hideOffline = Options.getBoolean(Options.OPTION_CL_HIDE_OFFLINE);
   ((RosterContent) content).setModel(getUpdater().getModel());
 }
예제 #6
0
 public void setModel(ContactListModel model) {
   ((RosterContent) content).setAllToTop();
   ((RosterContent) content).setModel(model);
   updateTitle();
   invalidate();
 }
예제 #7
0
 public void setCLListener(ContactListListener listener) {
   ((RosterContent) content).setCLListener(listener);
 }
예제 #8
0
 public final void setActiveContact(Contact cItem) {
   ((RosterContent) content).setActiveContact(cItem);
 }
예제 #9
0
 public void updateOption() {
   ((RosterContent) content).updateOption();
 }