[FL-1510] Archive: OK fix (#551)
This commit is contained in:
		
							parent
							
								
									0e8adcfdba
								
							
						
					
					
						commit
						c27d76d664
					
				| @ -554,16 +554,18 @@ static bool archive_view_input(InputEvent* event, void* context) { | ||||
| 
 | ||||
|     if(event->key == InputKeyOk) { | ||||
|         ArchiveFile_t* selected; | ||||
| 
 | ||||
|         with_view_model( | ||||
|             archive->view_archive_main, (ArchiveViewModel * model) { | ||||
|                 if(files_array_size(model->files) > 0) { | ||||
|                     selected = files_array_get(model->files, model->idx); | ||||
|                 } | ||||
| 
 | ||||
|                 selected = files_array_size(model->files) > 0 ? | ||||
|                                files_array_get(model->files, model->idx) : | ||||
|                                NULL; | ||||
|                 return true; | ||||
|             }); | ||||
| 
 | ||||
|         if(selected) { | ||||
|             string_set(archive->browser.name, selected->name); | ||||
| 
 | ||||
|             if(selected->type == ArchiveFileTypeFolder) { | ||||
|                 if(event->type == InputTypeShort) { | ||||
|                     archive_enter_dir(archive, archive->browser.name); | ||||
| @ -576,6 +578,7 @@ static bool archive_view_input(InputEvent* event, void* context) { | ||||
|                 } | ||||
|             } | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     update_offset(archive); | ||||
| 
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 its your bedtime
						its your bedtime