Commit Graph

40 Commits

Author SHA1 Message Date
André Berg ff550e85f1 More cleanup and feature adding for the Push, Pull and Rebase popup button toolbar items.
- Complete the action methods for fetch and rebase. 
- Add a more generic and re-usable method for updating the popup toolbar items.
- Comment out updatePushMenuWithRemotes: and updatePullMenuWithRemotes: as those have been 
  superseded by updatePopUpToolbarItemMenu:remotes:action:title:
2009-11-10 12:41:02 +01:00
brotherbard a26bca8845 Add drop down menus to the push and pull toolbar items.
TODO: need small disclosure triangles in the bottom right corner of the icons.
2009-11-08 20:34:34 -07:00
brotherbard 0be790dad4 merge andreberg/master 2009-11-08 18:19:41 -07:00
brotherbard d365bd44f5 Add a "Create Tag" button to the toolbar.
TODO: a custom icon
2009-11-08 15:51:56 -07:00
brotherbard c52aedfcf2 Add an "Add Remote" button to the toolbar that adds and fetches a remote.
TODO: a custom icon
2009-11-08 10:06:37 -07:00
André Berg 2c6fd97b5c Cosmetic: Move showMessageSheet convenience method to the proper pragma mark section. 2009-11-08 16:30:18 +01:00
André Berg 1ade0f0620 Remove completely wrong TODO comment.
A deletion execution dialog should block the UI until it's complete if there could
potentionally be state change occurring which has different outcome for pre-deletion
or post-deletion finite state.

A middle ground solution would be to use a modal sheet attached to a specific document
which then only blocks this particular document.
2009-11-08 16:28:50 +01:00
André Berg 1a7b4cb4c7 Update branch menu after deletion of a branch. 2009-11-08 16:26:07 +01:00
André Berg 22ba33f575 Disable/re-enable Push, Pull and Rebase buttons depending on selected branch validity.
If "All branches" or "Local branches" is selected, the buttons will be disabled. 
Actions from the context menu continue to work as they implicitly set the target branch
through the identity of the clicked label patch.
Any other branch will re-enable the buttons.
2009-11-08 16:22:53 +01:00
brotherbard 5e126433f6 Bug fix: Move updating the current branch to the checkoutRef method.
Stops the branch from being updated back to the current branch when the Refresh Automatically preference is on.
2009-11-07 23:22:20 -07:00
brotherbard 9e72dba3e3 PBRefController: Switch the app modal Delete Remote panel to a window modal sheet. 2009-11-07 19:47:38 -07:00
André Berg f1fcb18a92 Improve error and tooltip descriptions. 2009-11-07 04:20:24 +01:00
André Berg 4c4203a7ce Update PBGitErrors to include some error messages dealing with missing remote tracking branches.
This is especially useful for the new button functionality.
2009-11-07 01:02:22 +01:00
André Berg 93a027cccd Bug fix: Make new buttons actually work.
Mind you, these buttons cannot operate on the clicked branch like the context menu. 
Instead they always operate on the currently active branch (or its default remote).
2009-11-03 04:38:30 +01:00
André Berg 7c1b9d9961 Add pullButton: IBAction. 2009-11-01 00:29:07 +01:00
Morgan Schweers 7eb3616f3f Disable toolbar entries when they are processing, as at least some minimal feedback for the user. I still think it needs a progress bar dialog, or something. 2009-10-26 16:31:35 +01:00
André Berg 2b0000ca23 Add menu and toolbar changes from cyberfox 2009-10-26 16:26:52 +01:00
Morgan Schweers b580c03795 DRY up the menu adding code
Add rebase and pull menu items
Get upstream name more git-accurately for upstream operations
2009-10-26 16:16:04 +01:00
Morgan Schweers cdc4f5208b Add a menu item and an action for pushing a repo up. 2009-10-26 16:15:35 +01:00
Johannes Gilger 13746a5a6b PBGitWindowController: Use beginSheetModalForWindow instead of runModal
Introduce a new showMessageSheet/showErrorSheet-method for
PBGitWindowController which uses the beginSheetModalForWindow method of
NSAlert whereever possible. This has the advantage over runModal as it
doesn't block the other instances of GitX and is generally more
unobstrusive for simple status-messages.

Signed-off-by: Johannes Gilger <heipei@hackvalue.de>
2009-06-09 18:33:02 +02:00
Johannes Gilger 64b977e9c8 PBGitRepository: Add method to remove branch
This adds a removeBranch method similar to the addBranch method. It
calls these methods when a branch is created/deleted in the UI, avoiding
the cost of simply calling refresh afterwards.

Signed-off-by: Johannes Gilger <heipei@hackvalue.de>
2009-06-06 17:23:51 +01:00
Pieter de Bie 38198a9e27 Merge branch 'stable'
* stable:
  GitRevList -- Try to read the encoding of the commit message
  GitRevList: fix crash when loading 0 commits
  Tickets #151 and #155: check for illegal branch names before creating.
2009-05-28 15:12:16 +01:00
Charles O'Rourke 353d1053b0 Tickets #151 and #155: check for illegal branch names before creating. 2009-05-28 13:46:12 +01:00
Pieter de Bie 7caf7d799a Merge branch 'stable'
* stable:
  Fix many gcc 4.2 compiler warnings
  GitX.xcodeproj: Quote paths in custom shell scripts
  Fix compilation with GCC 4.2
  IndexController: Temporarily stop tracking when (un)staging
  IndexController: Add methods to stop tracking the Index
  ChangesTableView: Remove warning by casting to correct class

Conflicts:
	PBGitCommitController.m
2009-05-18 23:11:11 +01:00
Benjamin Kramer 6dcefe5bec Fix many gcc 4.2 compiler warnings 2009-05-18 23:08:51 +01:00
Mike Czepiel 7e74efba0d Added very basic tag info menu item and alert.
Simply renders the tag message when activated.
This would also make sense being available in
the web view somewhere.
2009-05-18 22:55:27 +01:00
Johannes Gilger 49a21e655f PBRefController: Ask for confirmation when deleting tags/branches
Show a very simple user-dialog when trying to delete a branch or a
tag.
This satisfies ticket #115.

Signed-off-by: Johannes Gilger <heipei@hackvalue.de>
2009-03-28 22:32:59 +00:00
Pieter de Bie 971e8e5bcc PBRefController: Only set title if we have a rev
We used to unconditionally set the title of the branch
to the current branch. This worked fine in most cases
where the current branch was already known, but failed
when you use 'gitx -c' and then switch to the HistoryView,
because then the currentBranch isn't known yet.

The simple fix is to check if we know it. If we don't,
it'll be set later on.
2009-01-19 22:20:16 +00:00
Mark Bestley 35f20cddd5 GitRefController: Fix moving and updating branches
This was also broken with the libgit2 move
2008-12-01 13:59:29 +01:00
Pieter de Bie 32e30ad351 HistoryView: Always show the correct current branch 2008-11-19 02:21:13 +01:00
Pieter de Bie b2c03bc97b HistoryView: Correctly update branches when changing them
I stupidly used "observe.." instead of register.. so KVC
didn't even work
2008-11-19 02:12:03 +01:00
Pieter de Bie a62e14ffe7 HistoryView: Remove the BranchController
This wasn't used anyway. A good idea would be to create a new
branchcontroller that takes care of all these revs, rather than
letting PBGitRepository take care of that
2008-11-19 01:54:14 +01:00
Pieter de Bie 92437c6663 WIP: Use a nicer branches menu 2008-11-19 01:41:27 +01:00
Pieter de Bie a950505972 PBRefController: reload items when checking out branch
This will update the view with the new current branch.
2008-11-17 14:03:06 +01:00
Pieter de Bie 00e44b35d0 RefController: Allow checking out branches 2008-11-01 23:24:41 +01:00
Pieter de Bie 058fbcff58 RefController: Refactor ref menu to its own class 2008-11-01 23:16:41 +01:00
Pieter de Bie e02ee5231c WebHistoryController: Move ref deletion to RefController
That's why it's there, after all. This also makes the system
more robust and catches some more errors.

The next thing this enables is to also allow right-clicking
on refs in the commit list.
2008-11-01 22:51:10 +01:00
Pieter de Bie 8a399c0793 GitCommit: Add a 'removeRef' function
The ref functionality is somewhat weird right now, in that
some parts of the code require a nil array when there are no
refs. So, we add a good removeRef accessor to keep track of this
2008-11-01 22:51:10 +01:00
Pieter de Bie 23c918660c HistoryView: Allow creation of branches 2008-11-01 22:51:10 +01:00
Pieter de Bie 4cefe8ee92 HistoryView: Allow dragging of refs to move them 2008-11-01 21:14:24 +01:00