예제 #1
0
 public override void ViewDidLoad()
 {
     base.ViewDidLoad ();
     customnav = new TSCustomNavController ();
     //if (UserInterfaceIsPhone)
     customnav.PushViewController (new TSLoginVC (), false);
     //else
     //				customnav.PushViewController (new TSSplitVCIPad (), false);
     SidebarController = new SidebarNavigation.SidebarController(this, customnav, new TSLeftSideMenuController ());
     SidebarController.MenuLocation = SidebarNavigation.SidebarController.MenuLocations.Left;
     SidebarController.FlingVelocity = 300f;
     SidebarController.MenuWidth = (int)TSPhoneSpec.MenuWidth;
     customnav.MenuButton.TouchUpInside += (sender, e) => {
         SidebarController.ToggleMenu ();
     };
 }
예제 #2
0
 public override void ViewDidLoad()
 {
     base.ViewDidLoad();
     customnav = new TSCustomNavController();
     //if (UserInterfaceIsPhone)
     customnav.PushViewController(new TSSettingsView(), false);
     //else
     //	customnav.PushViewController (new TSSplitVCIPad (), false);
     SidebarController = new SidebarNavigation.SidebarController(this, customnav, new TSLeftSideMenuController());
     SidebarController.MenuLocation      = SidebarNavigation.SidebarController.MenuLocations.Left;
     SidebarController.FlingVelocity     = 300f;
     SidebarController.MenuWidth         = (int)TSPhoneSpec.MenuWidth;
     customnav.MenuButton.TouchUpInside += (sender, e) => {
         SidebarController.ToggleMenu();
     };
 }
예제 #3
0
        public override void ViewDidLoad()
        {
            base.ViewDidLoad ();
            if (UserInterfaceIsPhone) {
                SetIPhoneLayout ();
            }

            Appdata.setViewBorder (viewShortCode);
            Appdata.setViewBorder (viewLongcode1);
            Appdata.setViewBorder (viewLongcode2);
            Appdata.setViewBorder1 (searchBoxView);

            //			pickerViewModel();

            this.NavigationItem.HidesBackButton = true;
            TSCustomNavController nav1 = new TSCustomNavController ();

            sortCodeList.Add ("1111");
            sortCodeList.Add ("2222");
            sortCodeList.Add ("3333");
            sortCodeList.Add ("4444");
            sortCodeList.Add ("5555");
            sortCodeList.Add ("6666");
            sortCodeList.Add ("7777");

            longCodeList.Add ("1111-1111");
            longCodeList.Add ("2222-1111");
            longCodeList.Add ("3333-1111");
            longCodeList.Add ("4444-1111");
            longCodeList.Add ("5555-1111");
            longCodeList.Add ("6666-1111");
            longCodeList.Add ("7777-1111");

            txtSearch.ResignFirstResponder ();
            tblSetupCodes.SeparatorInset = new UIEdgeInsets (0, 0, 0, 0);
            tblSetupCodes.BackgroundColor = UIColor.White;
            tblSetupCodes.AllowsSelection = true;
            tblSetupCodes.SeparatorStyle = UITableViewCellSeparatorStyle.SingleLine;
            tblSetupCodes.Source = new TSSetupCodesSource (this, items, txtSearch.Text);
            tblSetupCodes.ReloadData ();

            txtSearch.ShouldReturn += TextFieldShouldReturn;
            // Remove this comment

            txtSearch.EditingChanged += (object sender, EventArgs e) => {

                if(txtSearch.Text.Length != 0){
                    List<string> longCodeList;
                    longCodeList = ContactData.searchLongCode (items, txtSearch.Text);
                    tblSetupCodes.Source = new TSSetupCodesSource (this, longCodeList, txtSearch.Text);
                }else{
                    tblSetupCodes.Source = new TSSetupCodesSource (this, items, txtSearch.Text);
                }
                tblSetupCodes.ReloadData();
            };
        }