Exemplo n.º 1
0
        protected virtual void OnButtonAddBranchClicked(object sender, EventArgs e)
        {
            var dlg = new EditBranchDialog(repo, null, true);

            try {
                if (MessageService.RunCustomDialog(dlg) == (int)ResponseType.Ok)
                {
                    repo.CreateBranch(dlg.BranchName, dlg.TrackSource);
                    FillBranches();
                }
            } finally {
                dlg.Destroy();
            }
        }
Exemplo n.º 2
0
        protected virtual void OnButtonAddBranchClicked(object sender, EventArgs e)
        {
            var dlg = new EditBranchDialog(repo);

            try {
                if (MessageService.RunCustomDialog(dlg) == (int)ResponseType.Ok)
                {
                    repo.CreateBranch(dlg.BranchName, dlg.TrackSource, dlg.TrackRef);
                    FillBranches();
                }
            } catch (Exception ex) {
                MessageService.ShowError(GettextCatalog.GetString("The branch could not be created"), ex);
            } finally {
                dlg.Destroy();
                dlg.Dispose();
            }
        }