Commit Graph

23 Commits

Author SHA1 Message Date
Nathan Kinsinger 87f76fd5a1 Bugfix: fix the contextual menu and drag-n-drop of refs
When the Subject column is not the first column in the git history table the contextual menu for refs and dragging and dropping refs don't work.

Offset the mouse click's x value by the x origin of the Subject column.

In PBRefController look up the column index of the subject column and check that it's the clicked column (don't assume it's the first one).
2010-02-19 22:54:25 -07:00
Nathan Kinsinger fbc1902764 Switch Delete Remote panel to a window modal sheet 2010-02-19 22:26:14 -07: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