public static ViewItemGroup buildLoginUI(ModelApplication modelApp,Activity activity){
  ViewItemGroup viewItems=new ViewItemGroup(activity);
  TextView usernameText=new TextView(activity);
  usernameText.setText(R.string.username);
  viewItems.addView(usernameText);
  ViewItemFactory viewItemFactory=ViewItemFactory.instance();
  ViewItem usernameItem=viewItemFactory.create(LoginViewID.USERNAME,viewItemFactory.TEXT_DATATYPE_DB_ID,activity);
  viewItems.addViewItem(usernameItem,new OmniText(modelApp.getUsername()));
  TextView passwordText=new TextView(activity);
  passwordText.setText(R.string.password);
  viewItems.addView(passwordText);
  ViewItem passwordItem=viewItemFactory.create(LoginViewID.PASSWORD,viewItemFactory.PASSWORD_INPUT_DATATYPE_DB_ID,activity);
  viewItems.addViewItem(passwordItem,new OmniPasswordInput(modelApp.getPassword()));
  return viewItems;
}

public static ViewItemGroup buildLoginUI ( ModelApplication modelApp , Activity activity ) { ViewItemGroup viewItems = new ViewItemGroup ( activity ) ; TextView usernameText = new TextView ( activity ) ; usernameText . setText ( R . string . username ) ; viewItems . addView ( usernameText ) ; ViewItemFactory viewItemFactory = ViewItemFactory . instance ( ) ; ViewItem usernameItem = viewItemFactory . create ( LoginViewID . USERNAME , viewItemFactory . TEXT_DATATYPE_DB_ID , activity ) ; viewItems . addViewItem ( usernameItem , new OmniText ( modelApp . getUsername ( ) ) ) ; TextView passwordText = new TextView ( activity ) ; passwordText . setText ( R . string . password ) ; viewItems . addView ( passwordText ) ; ViewItem passwordItem = viewItemFactory . create ( LoginViewID . PASSWORD , viewItemFactory . PASSWORD_INPUT_DATATYPE_DB_ID , activity ) ; viewItems . addViewItem ( passwordItem , new OmniPasswordInput ( modelApp . getPassword ( ) ) ) ; return viewItems ; }
build a standard login ui with username and password fields
