File tree Expand file tree Collapse file tree 3 files changed +12
-9
lines changed Expand file tree Collapse file tree 3 files changed +12
-9
lines changed Original file line number Diff line number Diff line change @@ -91,7 +91,7 @@ internal set
91
91
if ( value != selectedItems )
92
92
{
93
93
selectedItems = value ;
94
- if ( selectedItems . Count == 0 )
94
+ if ( selectedItems . Count == 0 || selectedItems [ 0 ] == null )
95
95
{
96
96
IsItemSelected = false ;
97
97
SelectedItem = null ;
Original file line number Diff line number Diff line change @@ -176,8 +176,11 @@ public override void FocusSelectedItems()
176
176
177
177
public override void StartRenameItem ( )
178
178
{
179
- AllView . CurrentColumn = AllView . Columns [ 1 ] ;
180
- AllView . BeginEdit ( ) ;
179
+ if ( AllView . SelectedIndex != - 1 )
180
+ {
181
+ AllView . CurrentColumn = AllView . Columns [ 1 ] ;
182
+ AllView . BeginEdit ( ) ;
183
+ }
181
184
}
182
185
183
186
private void ViewModel_PropertyChanged ( object sender , PropertyChangedEventArgs e )
Original file line number Diff line number Diff line change @@ -1115,17 +1115,17 @@ await FilesystemHelpers.DeleteItemsAsync(
1115
1115
break ;
1116
1116
} ;
1117
1117
1118
- if ( CurrentPageType == typeof ( GridViewBrowser ) )
1118
+ switch ( args . KeyboardAccelerator . Key )
1119
1119
{
1120
- switch ( args . KeyboardAccelerator . Key )
1121
- {
1122
- case VirtualKey . F2 : //F2, rename
1120
+ case VirtualKey . F2 : //F2, rename
1121
+ if ( CurrentPageType == typeof ( GenericFileBrowser ) || CurrentPageType == typeof ( GridViewBrowser ) )
1122
+ {
1123
1123
if ( ContentPage . IsItemSelected )
1124
1124
{
1125
1125
InteractionOperations . RenameItem_Click ( null , null ) ;
1126
1126
}
1127
- break ;
1128
- }
1127
+ }
1128
+ break ;
1129
1129
}
1130
1130
}
1131
1131
You can’t perform that action at this time.
0 commit comments