public override bool ApplyChanges()
        {
            EnsureChildControls();
            WebExplorer webpart = WebPartToEdit as WebExplorer;

            if (webpart != null)
            {
                webpart.RootWeb      = txtRootWeb.Text;
                webpart.ShowSubSites = chkShowSubsites.Checked;
                webpart.ShowLists    = chkShowLists.Checked;
                webpart.ShowFolders  = chkShowFolders.Checked;
                webpart.FilterWeb    = txtFilterWeb.Text;
                webpart.FilterList   = txtFilterList.Text;

                int converted;
                if (int.TryParse(txtExpandDepth.Text, out converted))
                {
                    webpart.ExpandDepth = converted;
                }

                webpart.ClearControlState();
                webpart.ClearCache();

                return(true);
            }
            return(false);
        }
        public override void SyncChanges()
        {
            EnsureChildControls();
            WebExplorer webpart = WebPartToEdit as WebExplorer;

            if (webpart != null)
            {
                txtRootWeb.Text         = webpart.RootWeb;
                chkShowSubsites.Checked = webpart.ShowSubSites;
                chkShowLists.Checked    = webpart.ShowLists;
                chkShowFolders.Checked  = webpart.ShowFolders;
                txtFilterWeb.Text       = webpart.FilterWeb;
                txtFilterList.Text      = webpart.FilterList;
                txtExpandDepth.Text     = webpart.ExpandDepth.ToString();
            }
        }