diff --git a/apps/mtxchat/README.md b/apps/mtxchat/README.md index 6809c02a8..6ec9cac17 100644 --- a/apps/mtxchat/README.md +++ b/apps/mtxchat/README.md @@ -40,9 +40,9 @@ mtxchat provides the following basic functionality: The `mtxchat` code is primarily concerned with the [matrix] specific protocols, while the Chat library handles the UI and pddb storage. -Much of the code in `main.rs` & `lib.rs` has been adapted from `mtxcli`, while `url.rs` and `web.rs` are simple copies. +Much of the code in `main.rs` `lib.rs` `web.rs` & `url.rs` has been adapted from `mtxcli`. -The Chat library provides the UI to display a series of matrix events (Posts) in a matrix room (Dialogue) stored in the pddb. Each Dialogue is stored in the `pddb:dict` `mtxchat` under a descriptive `pddb:key` (ie `#xous-apps:matrix.org`). +The Chat library provides the UI to display a series of matrix events (Posts) in a matrix room (Dialogue) stored in the pddb. Each Dialogue is stored in the `pddb:dict` `mtxchat.dialogue` under a descriptive `pddb:key` (ie `#xous-apps:matrix.org`). `mtxchat` passes a menu to the Chat UI: * `room` to type a [matrix] room/server diff --git a/apps/mtxchat/src/lib.rs b/apps/mtxchat/src/lib.rs index 62e14289d..33d6cb16d 100644 --- a/apps/mtxchat/src/lib.rs +++ b/apps/mtxchat/src/lib.rs @@ -316,11 +316,13 @@ impl<'a> MtxChat<'a> { self.set_debug(TOKEN_KEY, &new_token); self.logged_in = true; } else { - log::info!( + log::warn!( "Error: cannnot login with type: {}", web::MTX_LOGIN_PASSWORD ); } + } else { + log::warn!("failed to web::get_login_type()"); } } if self.logged_in { @@ -654,10 +656,12 @@ impl<'a> MtxChat<'a> { // returns true if "Connect to WiFi?" yes option is chosen // - fn wifi_try_modal (&self) -> bool { + fn wifi_try_modal(&self) -> bool { self.modals.add_list_item("yes").expect("failed radio yes"); self.modals.add_list_item("no").expect("failed radio no"); - self.modals.get_radiobutton("Connect to WiFi?").expect("failed radiobutton modal"); + self.modals + .get_radiobutton("Connect to WiFi?") + .expect("failed radiobutton modal"); match self.modals.get_radio_index() { Ok(button) => button == 0, _ => false, diff --git a/libs/chat/src/api.rs b/libs/chat/src/api.rs index b3454f095..587b36bbe 100644 --- a/libs/chat/src/api.rs +++ b/libs/chat/src/api.rs @@ -25,6 +25,8 @@ pub enum ChatOp { GamRawkeys, /// redraw our Chat UI GamRedraw, + /// Show some user help + Help, /// Add a new MenuItem to the App menu MenuAdd, /// Add a new Post to the Dialogue diff --git a/libs/chat/src/ui.rs b/libs/chat/src/ui.rs index 32632d6fa..21fa5508a 100644 --- a/libs/chat/src/ui.rs +++ b/libs/chat/src/ui.rs @@ -149,7 +149,7 @@ impl Ui { (Some(dict), Some(key)) => { match self .pddb - .get(&dict, &key, None, false, false, None, None::) + .get(&dict, &key, None, true, false, None, None::) { Ok(mut pddb_key) => { let mut bytes = [0u8; dialogue::MAX_BYTES + 2];