File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -218,25 +218,27 @@ impl App {
218
218
*/
219
219
pub fn show_help_message ( & mut self , kernel_modules : & mut KernelModules < ' _ > ) {
220
220
let key_bindings: Vec < ( & str , & str ) > = util:: KEY_BINDINGS . to_vec ( ) ;
221
-
222
221
let mut help_text = Vec :: new ( ) ;
222
+ let mut help_text_raw = Vec :: new ( ) ;
223
223
for ( key, desc) in & key_bindings {
224
224
help_text. push ( Spans :: from ( Span :: styled (
225
- format ! ( "{}:" , key) ,
225
+ format ! ( "{}:" , & key) ,
226
226
self . style . colored ,
227
227
) ) ) ;
228
+ help_text_raw. push ( format ! ( "{}:" , key) ) ;
228
229
help_text. push ( Spans :: from ( Span :: styled (
229
- format ! ( "{}{}" , self . style. unicode. get( Symbol :: Blank ) , desc) ,
230
+ format ! ( "{}{}" , self . style. unicode. get( Symbol :: Blank ) , & desc) ,
230
231
self . style . default ,
231
232
) ) ) ;
233
+ help_text_raw. push ( format ! ( " {}" , & desc) ) ;
232
234
}
233
235
kernel_modules. info_scroll_offset = 0 ;
234
236
kernel_modules. command = ModuleCommand :: None ;
235
237
kernel_modules. current_name =
236
238
format ! ( "!Help{}" , self . style. unicode. get( Symbol :: Helmet ) ) ;
237
239
kernel_modules
238
240
. current_info
239
- . set ( Text :: from ( help_text) , kernel_modules . current_name . clone ( ) ) ;
241
+ . set ( Text :: from ( help_text) , help_text_raw . join ( " \n " ) ) ;
240
242
}
241
243
242
244
/**
You can’t perform that action at this time.
0 commit comments