public PushDialog(MercurialRepository repo)
        {
            this.Build ();
            this.repo = repo;
            HasSeparator = false;

            changeList.DiffLoader = DiffLoader;

            List<string> list = new List<string> (repo.GetRemotes ().Select (r => r.Name));
            foreach (string s in list)
                remoteCombo.AppendText (s);
            remoteCombo.Active = list.IndexOf (repo.GetCurrentRemote ());

            UpdateChangeSet ();
        }
示例#2
0
        public PushDialog(MercurialRepository repo)
        {
            this.Build();
            this.repo    = repo;
            HasSeparator = false;

            changeList.DiffLoader = DiffLoader;

            List <string> list = new List <string> (repo.GetRemotes().Select(r => r.Name));

            foreach (string s in list)
            {
                remoteCombo.AppendText(s);
            }
            remoteCombo.Active = list.IndexOf(repo.GetCurrentRemote());

            UpdateChangeSet();
        }
示例#3
0
        void FillRemotes()
        {
            TreeViewState state = new TreeViewState(treeRemotes, 4);

            state.Save();
            storeRemotes.Clear();
            string currentRemote = repo.GetCurrentRemote();

            foreach (var remote in repo.GetRemotes())
            {
                string   text = remote.Name == currentRemote ? "<b>" + remote.Name + "</b>" : remote.Name;
                string   url  = remote.Path;
                TreeIter it   = storeRemotes.AppendValues(remote, text, url, null, remote.Name);
                foreach (string branch in repo.GetRemoteBranches(remote.Name))
                {
                    storeRemotes.AppendValues(it, null, branch, null, branch, remote.Name + "/" + branch);
                }
            }
            state.Load();
        }