Пример #1
0
        public override void ViewDidDisappear(bool animated)
        {
            base.ViewDidDisappear(animated);

            AutoCompleteTextFieldManager.RemoveTable();

            //AutoCompleteTextFieldManager.RemoveAll();
        }
Пример #2
0
        private bool TextFieldShoulClear(UITextField textfield)
        {
            textfield.Text = "";

            if (textfield == txtLocation)
            {
                AutoCompleteTextFieldManager.RemoveTable();
            }

            return(true);
        }
Пример #3
0
        private bool TextFieldShouldReturn(UITextField textfield)
        {
            textfield.ResignFirstResponder();

            if (textfield == txtLocation)
            {
                AutoCompleteTextFieldManager.RemoveTable();
            }

            return(true);
        }
Пример #4
0
        public override void ViewWillAppear(bool animated)
        {
            base.ViewWillAppear(animated);

            View.EndEditing(true);

            AutoCompleteTextFieldManager.RemoveTable();
            AutoCompleteTextFieldManager.RemoveAll();

            this.Title = "Branch Locator";
        }
Пример #5
0
        private bool TextFieldShoulClear(UITextField textfield)
        {
            //if(textfield == txtKeyword)
            //	AutoCompleteTextFieldManager.RemoveTable(1, 0);

            //if (textfield == txtLocation)
            //	AutoCompleteTextFieldManager.RemoveTable(2, 1);

            AutoCompleteTextFieldManager.RemoveTable();
            AutoCompleteTextFieldManager.RemoveAll();

            return(true);
        }
Пример #6
0
        public override void TouchesBegan(NSSet touches, UIEvent evt)
        {
            base.TouchesBegan(touches, evt);
            UITouch touch = touches.AnyObject as UITouch;

            if (touch.View == View)
            {
                txtLocation.ResignFirstResponder();
                txtDistance.ResignFirstResponder();
                AutoCompleteTextFieldManager.RemoveTable();
                txtLocation.TouchDown += delegate
                {
                    AutoCompleteTextFieldManager.RemoveTable();
                };
            }
        }
Пример #7
0
        private bool TextFieldShouldReturn(UITextField textfield)
        {
            int         nextTag       = (int)textfield.Tag + 1;
            UIResponder nextResponder = this.View.ViewWithTag(nextTag);

            if (nextResponder != null)
            {
                nextResponder.BecomeFirstResponder();
                AutoCompleteTextFieldManager.RemoveTable();
            }
            else
            {
                // Not found, so remove keyboard.
                textfield.ResignFirstResponder();
            }

            return(false);            // We do not want UITextField to insert line-breaks.
        }
Пример #8
0
        public override void ViewWillAppear(bool animated)
        {
            base.ViewWillAppear(animated);

            if (jobList != null)
            {
                tblView.ReloadData();
            }

            View.EndEditing(true);
            this.FavoriteButtonWithCount(NavigationItem);
            tblView.AllowsSelection = true;

            AutoCompleteTextFieldManager.RemoveTable();
            AutoCompleteTextFieldManager.RemoveAll();


            // clear filetr url used for refine
            Constants.FilterURL         = "";
            Constants.jobSearchResponse = new Dictionary <string, dynamic>();

            AppDelegate appDelegate = (AppDelegate)UIApplication.SharedApplication.Delegate;

            appDelegate.SidebarController.Disabled = false;


            // Now Get latest jobs if config file changed
            if (Constants.isConigurationChanged)
            {
                this.txtKeyword.Text  = "";
                this.txtLocation.Text = "";

                btnJobSearch.SetTitle(Translations.job_search, UIControlState.Normal);
                btnJobSearch.SetTitle(Translations.job_search, UIControlState.Highlighted);

                segmentCtrl.RemoveAllSegments();
                segmentCtrl.InsertSegment(Translations.latest_job, 0, false);
                segmentCtrl.InsertSegment(Translations.recent_search, 1, false);
                segmentCtrl.SelectedSegment = 0;

                this.txtKeyword.AttributedPlaceholder = new NSAttributedString(
                    Translations.keyword_title,
                    font: UIFont.SystemFontOfSize(15),
                    foregroundColor: UIColor.White,
                    strokeWidth: 0
                    );

                this.txtLocation.AttributedPlaceholder = new NSAttributedString(
                    Translations.location_title,
                    font: UIFont.SystemFontOfSize(15),
                    foregroundColor: UIColor.White,
                    strokeWidth: 0
                    );

                DbHelper.ResetDatabase();
                DbHelper.CreateDatabaseAndTables();

                _recentSearchs = DbHelper.GetRecentSearches();

                this.FavoriteButtonWithCount(NavigationItem);

                GetJobSearchData("", "");

                Constants.isConigurationChanged = false;
            }
        }