コード例 #1
0
        public void Dispose()
        {
            if (calendar != null)
            {
                calendar.Dispose();
                calendar = null;
            }

            if (mainLayout != null)
            {
                mainLayout.Dispose();
                mainLayout = null;
            }

            if (proprtyOptionsLayout != null)
            {
                proprtyOptionsLayout.Dispose();
                proprtyOptionsLayout = null;
            }

            if (dataAdapter != null)
            {
                dataAdapter.Dispose();
                dataAdapter = null;
            }

            if (cultureSpinner != null)
            {
                cultureSpinner.Dispose();
                cultureSpinner = null;
            }
        }
コード例 #2
0
        public void Dispose()
        {
            if (calendar != null)
            {
                calendar.Dispose();
                calendar = null;
            }

            if (mainView != null)
            {
                mainView.Dispose();
                mainView = null;
            }

            if (culturetxt != null)
            {
                culturetxt.Dispose();
                culturetxt = null;
            }

            if (cultureSpinner != null)
            {
                cultureSpinner.Dispose();
                cultureSpinner = null;
            }

            if (layoutParams1 != null)
            {
                layoutParams1.Dispose();
                layoutParams1 = null;
            }

            if (separate != null)
            {
                separate.Dispose();
                separate = null;
            }

            if (propertylayout != null)
            {
                propertylayout.Dispose();
                propertylayout = null;
            }

            if (dataAdapter != null)
            {
                dataAdapter.Dispose();
                dataAdapter = null;
            }

            if (localinfo != null)
            {
                localinfo.Dispose();
                localinfo = null;
            }
        }
コード例 #3
0
        public void Dispose()
        {
            if (calendar != null)
            {
                calendar.Dispose();
                calendar = null;
            }
            if (dataAdapter != null)
            {
                dataAdapter.Dispose();
                dataAdapter = null;
            }

            if (modeSpinner != null)
            {
                modeSpinner.Dispose();
                modeSpinner = null;
            }

            if (mainView != null)
            {
                mainView.Dispose();
                mainView = null;
            }

            if (separatorLayoutParams != null)
            {
                separatorLayoutParams.Dispose();
                separatorLayoutParams = null;
            }

            if (separate != null)
            {
                separate.Dispose();
                separate = null;
            }

            if (propertylayout != null)
            {
                propertylayout.Dispose();
                propertylayout = null;
            }

            if (viewModetxt != null)
            {
                viewModetxt.Dispose();
                viewModetxt = null;
            }
        }
コード例 #4
0
        /// <summary>
        /// Internal clean up
        /// </summary>
        public void Dispose()
        {
            pcNames.Dispose();
            pcUrls.Dispose();
            pcDurations.Dispose();
            pcPassages.Dispose();
            pcDates.Dispose();
            items.Clear();
            urls.Clear();
            durs.Clear();
            passages.Clear();
            dates.Clear();

            Main.Dispose();
        }
コード例 #5
0
        public override View OnCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState)
        {
            base.OnCreateView(inflater, container, savedInstanceState);

            var view = inflater.Inflate(Resource.Layout.PopupWindow, container, false);

            using (EditText editTextTime = view.FindViewById <EditText>(Resource.Id.editTextTime))
            {
                editTextTime.Text = note.TimeOfNote.Split(' ')[1];
            }
            using (EditText editTextDay = view.FindViewById <EditText>(Resource.Id.editTextDate))
            {
                editTextDay.Text = note.TimeOfNote.Split(' ')[0];
            }
            using (EditText editTextNote = view.FindViewById <EditText>(Resource.Id.editTextOfNote))
            {
                editTextNote.Text = note.TextOfNote;
            }
            using (Spinner spinner = view.FindViewById <Spinner>(Resource.Id.spinner1))
            {
                spinner.ItemSelected += (s, e) =>
                {
                    using (Spinner spinnerID = view.FindViewById <Spinner>(Resource.Id.spinnerRoomID))
                    {
                        spinnerID.SetSelection(e.Position);
                    }
                };
                spinner.Adapter = adapterRoomName;
                int a = adapterRoomName.GetPosition(note.RoomName);
                spinner.SetSelection(adapterRoomName.GetPosition(note.RoomName));
                adapterRoomName.Dispose();
            }
            using (Spinner spinner = view.FindViewById <Spinner>(Resource.Id.spinnerRoomID))
            {
                spinner.Adapter = adapterRoomID;
                //spinner.SetSelection(adapterRoomID.GetPosition(room.RoomID));
                adapterRoomID.Dispose();
            }

            using (Button btn = view.FindViewById <Button>(Resource.Id.button2))
            {
                btn.Click += BtnSaveChanges_Click;
            }

            this.view = view;
            return(view);
        }
コード例 #6
0
ファイル: SearchFragment.cs プロジェクト: Berkays/DaVinci-App
        private void getSearchSuggestions()
        {
            if (searchField.Text.Length >= SEARCH_SUGGESTION_START_LENGTH)
            {
                //Get search suggestions
                Task.Run(async() =>
                {
                    return(await Api.DavinciApi.GetSearchSuggestions(searchField.Text));
                }).ContinueWith(t =>
                {
                    if (t.Status != TaskStatus.Canceled && t.Result.OK)
                    {
                        if (suggestionAdapter == null)
                        {
                            var items           = t.Result.results.Select(n => n.name.Capitalize()).ToArray();
                            suggestionAdapter   = new ArrayAdapter <string>(this.Context, Resource.Layout.Search_dropdownItem, items);
                            searchField.Adapter = suggestionAdapter;
                        }
                        else
                        {
                            suggestionAdapter.Clear();
                            suggestionAdapter.AddAll(t.Result.results.Select(n => n.name.Capitalize()).ToList());
                            suggestionAdapter.NotifyDataSetChanged();
                        }
                    }
                }, TaskScheduler.FromCurrentSynchronizationContext());
            }
            else
            {
                if (suggestionAdapter != null)
                {
                    suggestionAdapter.Dispose();
                    suggestionAdapter = null;
                }

                //Show most popular categories
                header.Text = "Most Popular Categories";
                searchRecyclerView.Visibility  = ViewStates.Gone;
                popularRecyclerView.Visibility = ViewStates.Visible;
            }
        }
コード例 #7
0
        public void Dispose()
        {
            if (calendar != null)
            {
                calendar.DrawMonthCell -= Calendar_DrawMonthCell;
                calendar.Dispose();
                calendar = null;
            }

            if (viewModetxt != null)
            {
                viewModetxt.Dispose();
                viewModetxt = null;
            }

            if (modeSpinner != null)
            {
                modeSpinner.Dispose();
                modeSpinner = null;
            }

            if (spaceAdder1 != null)
            {
                spaceAdder1.Dispose();
                spaceAdder1 = null;
            }

            if (spaceAdder2 != null)
            {
                spaceAdder2.Dispose();
                spaceAdder2 = null;
            }

            if (minDate != null)
            {
                minDate.Dispose();
                minDate = null;
            }

            if (maxDate != null)
            {
                maxDate.Dispose();
                maxDate = null;
            }

            if (minPick != null)
            {
                minPick.Dispose();
                minPick = null;
            }

            if (maxPick != null)
            {
                maxPick.Dispose();
                maxPick = null;
            }

            if (minDateButton != null)
            {
                minDateButton.Dispose();
                minDateButton = null;
            }

            if (maxDateButton != null)
            {
                maxDateButton.Dispose();
                maxDateButton = null;
            }

            if (mainView != null)
            {
                mainView.Dispose();
                mainView = null;
            }

            if (propertylayout != null)
            {
                propertylayout.Dispose();
                propertylayout = null;
            }

            if (minDatePicker != null)
            {
                minDatePicker.Dispose();
                minDatePicker = null;
            }

            if (maxDatePicker != null)
            {
                maxDatePicker.Dispose();
                maxDatePicker = null;
            }

            if (underMaxSeparatorLayoutParam != null)
            {
                underMaxSeparatorLayoutParam.Dispose();
                underMaxSeparatorLayoutParam = null;
            }

            if (minMaxSeparatorLayoutParam != null)
            {
                minMaxSeparatorLayoutParam.Dispose();
                minMaxSeparatorLayoutParam = null;
            }

            if (dataAdapter != null)
            {
                dataAdapter.Dispose();
                dataAdapter = null;
            }

            if (underMaxSeparator != null)
            {
                underMaxSeparator.Dispose();
                underMaxSeparator = null;
            }

            if (minMaxSeparator != null)
            {
                minMaxSeparator.Dispose();
                minMaxSeparator = null;
            }
        }
コード例 #8
0
        public void Dispose()
        {
            if (dataSource != null)
            {
                dataSource.Dispose();
                dataSource = null;
            }

            if (conditionDropdown != null)
            {
                conditionDropdown.Dispose();
                conditionDropdown = null;
            }

            if (columnDropdown != null)
            {
                columnDropdown.Dispose();
                columnDropdown = null;
            }

            if (filterText != null)
            {
                filterText.Dispose();
                filterText = null;
            }

            if (columnTextView != null)
            {
                columnTextView.Dispose();
                columnTextView = null;
            }

            if (conditionTextView != null)
            {
                conditionTextView.Dispose();
                conditionTextView = null;
            }

            if (condtionAdapter != null)
            {
                condtionAdapter.Dispose();
                condtionAdapter = null;
            }

            if (gridlayout != null)
            {
                gridlayout.Dispose();
                gridlayout = null;
            }

            if (columnDropdown != null)
            {
                columnDropdown.Dispose();
                columnDropdown = null;
            }

            if (groupTextView != null)
            {
                groupTextView.Dispose();
                groupTextView = null;
            }

            if (listView != null)
            {
                listView.Dispose();
                listView = null;
            }

            if (filterText != null)
            {
                filterText.Dispose();
                filterText = null;
            }
        }
コード例 #9
0
        public void Dispose()
        {
            if (calendar != null)
            {
                calendar.DrawMonthCell -= Calendar_DrawMonthCell;
                calendar.Dispose();
                calendar = null;
            }

            if (modeSpinner != null)
            {
                modeSpinner.Dispose();
                modeSpinner = null;
            }

            if (dataAdapter != null)
            {
                dataAdapter.Dispose();
                dataAdapter = null;
            }

            if (minPick != null)
            {
                minPick.Dispose();
                minPick = null;
            }

            if (maxPick != null)
            {
                maxPick.Dispose();
                maxPick = null;
            }

            if (mainLayout != null)
            {
                mainLayout.Dispose();
                mainLayout = null;
            }

            if (proprtyOptionsLayout != null)
            {
                proprtyOptionsLayout.Dispose();
                proprtyOptionsLayout = null;
            }

            if (minDatePicker != null)
            {
                minDatePicker.Dispose();
                minDatePicker = null;
            }

            if (maxDatePicker != null)
            {
                maxDatePicker.Dispose();
                maxDatePicker = null;
            }

            if (minDateButton != null)
            {
                minDateButton.Dispose();
                minDateButton = null;
            }

            if (maxDateButton != null)
            {
                maxDateButton.Dispose();
                maxDateButton = null;
            }
        }
コード例 #10
0
 public void Dispose()
 {
     ChurchNames.Dispose();
 }