File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -147,6 +147,7 @@ public void DoubleTapped(Models.Commit commit)
147147 if ( commit == null || commit . IsCurrentHead )
148148 return ;
149149
150+ var firstRemoteBranch = null as Models . Branch ;
150151 foreach ( var d in commit . Decorators )
151152 {
152153 if ( d . Type == Models . DecoratorType . LocalBranchHead )
@@ -158,10 +159,19 @@ public void DoubleTapped(Models.Commit commit)
158159 return ;
159160 }
160161 }
162+ else if ( d . Type == Models . DecoratorType . RemoteBranchHead && firstRemoteBranch == null )
163+ {
164+ firstRemoteBranch = _repo . Branches . Find ( x => x . FriendlyName == d . Name ) ;
165+ }
161166 }
162167
163168 if ( PopupHost . CanCreatePopup ( ) )
164- PopupHost . ShowPopup ( new CheckoutCommit ( _repo , commit ) ) ;
169+ {
170+ if ( firstRemoteBranch != null )
171+ PopupHost . ShowPopup ( new CreateBranch ( _repo , firstRemoteBranch ) ) ;
172+ else
173+ PopupHost . ShowPopup ( new CheckoutCommit ( _repo , commit ) ) ;
174+ }
165175 }
166176
167177 public ContextMenu MakeContextMenu ( DataGrid datagrid )
You can’t perform that action at this time.
0 commit comments