diff --git a/Cargo.lock b/Cargo.lock
index 5dccaff2..97ae0ccc 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -1931,7 +1931,7 @@ dependencies = [
[[package]]
name = "makepad-derive-live"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-live-id",
"makepad-micro-proc-macro",
@@ -1940,7 +1940,7 @@ dependencies = [
[[package]]
name = "makepad-derive-wasm-bridge"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-micro-proc-macro",
]
@@ -1948,7 +1948,7 @@ dependencies = [
[[package]]
name = "makepad-derive-widget"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-live-id",
"makepad-micro-proc-macro",
@@ -1957,7 +1957,7 @@ dependencies = [
[[package]]
name = "makepad-draw"
version = "0.6.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"ab_glyph_rasterizer",
"fxhash",
@@ -1972,17 +1972,17 @@ dependencies = [
[[package]]
name = "makepad-futures"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
[[package]]
name = "makepad-futures-legacy"
version = "0.7.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
[[package]]
name = "makepad-html"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-live-id",
]
@@ -1990,7 +1990,7 @@ dependencies = [
[[package]]
name = "makepad-http"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
[[package]]
name = "makepad-jni-sys"
@@ -2001,7 +2001,7 @@ checksum = "9775cbec5fa0647500c3e5de7c850280a88335d1d2d770e5aa2332b801ba7064"
[[package]]
name = "makepad-live-compiler"
version = "0.5.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-derive-live",
"makepad-live-tokenizer",
@@ -2011,7 +2011,7 @@ dependencies = [
[[package]]
name = "makepad-live-id"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-live-id-macros",
]
@@ -2019,7 +2019,7 @@ dependencies = [
[[package]]
name = "makepad-live-id-macros"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-micro-proc-macro",
]
@@ -2027,7 +2027,7 @@ dependencies = [
[[package]]
name = "makepad-live-tokenizer"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-live-id",
"makepad-math",
@@ -2037,7 +2037,7 @@ dependencies = [
[[package]]
name = "makepad-markdown"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-live-id",
]
@@ -2045,17 +2045,17 @@ dependencies = [
[[package]]
name = "makepad-math"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
[[package]]
name = "makepad-micro-proc-macro"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
[[package]]
name = "makepad-micro-serde"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-micro-serde-derive",
]
@@ -2063,7 +2063,7 @@ dependencies = [
[[package]]
name = "makepad-micro-serde-derive"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-micro-proc-macro",
]
@@ -2071,12 +2071,12 @@ dependencies = [
[[package]]
name = "makepad-objc-sys"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
[[package]]
name = "makepad-platform"
version = "0.6.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-android-state",
"makepad-futures",
@@ -2094,7 +2094,7 @@ dependencies = [
[[package]]
name = "makepad-rustybuzz"
version = "0.8.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"bitflags 1.3.2",
"bytemuck",
@@ -2109,7 +2109,7 @@ dependencies = [
[[package]]
name = "makepad-shader-compiler"
version = "0.5.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-live-compiler",
]
@@ -2117,7 +2117,7 @@ dependencies = [
[[package]]
name = "makepad-vector"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"ttf-parser",
]
@@ -2125,7 +2125,7 @@ dependencies = [
[[package]]
name = "makepad-wasm-bridge"
version = "0.4.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-derive-wasm-bridge",
"makepad-live-id",
@@ -2134,7 +2134,7 @@ dependencies = [
[[package]]
name = "makepad-widgets"
version = "0.6.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-derive-widget",
"makepad-draw",
@@ -2147,7 +2147,7 @@ dependencies = [
[[package]]
name = "makepad-windows"
version = "0.51.1"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"windows-core 0.51.1 (git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack)",
"windows-targets 0.48.5",
@@ -2156,7 +2156,7 @@ dependencies = [
[[package]]
name = "makepad-zune-core"
version = "0.2.14"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"bitflags 2.4.1",
]
@@ -2164,7 +2164,7 @@ dependencies = [
[[package]]
name = "makepad-zune-inflate"
version = "0.2.54"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"simd-adler32",
]
@@ -2172,7 +2172,7 @@ dependencies = [
[[package]]
name = "makepad-zune-jpeg"
version = "0.3.17"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-zune-core",
]
@@ -2180,7 +2180,7 @@ dependencies = [
[[package]]
name = "makepad-zune-png"
version = "0.2.1"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"makepad-zune-core",
"makepad-zune-inflate",
@@ -4584,7 +4584,7 @@ checksum = "3528ecfd12c466c6f163363caf2d02a71161dd5e1cc6ae7b34207ea2d42d81ed"
[[package]]
name = "ttf-parser"
version = "0.19.0"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
[[package]]
name = "typenum"
@@ -4958,7 +4958,7 @@ dependencies = [
[[package]]
name = "windows-core"
version = "0.51.1"
-source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#3dea7345ddd1ae82bd0a5e861960fc89ebfd832a"
+source = "git+https://github.com/kevinaboos/makepad?branch=rik_with_old_font_stack#149b4c28c892b9b859e9654fdfefe74c3ed338d5"
dependencies = [
"windows-targets 0.48.5",
]
diff --git a/README.md b/README.md
index c6de19e3..fdf9c5f4 100644
--- a/README.md
+++ b/README.md
@@ -115,3 +115,7 @@ These are generally sorted in order of priority. If you're interested in helping
- [ ] User profile settings screen
- [ ] Persistence of app state to disk
+
+## Known problems/issues
+ - URLs do not wrap properly; that is a Makepad-side problem.
+ - Matrix-specific links are not yet fully handled (https://matrix.to/...)
diff --git a/resources/icons/close.svg b/resources/icons/close.svg
new file mode 100644
index 00000000..4d5ee5b1
--- /dev/null
+++ b/resources/icons/close.svg
@@ -0,0 +1,3 @@
+
diff --git a/resources/icons/copy.svg b/resources/icons/copy.svg
new file mode 100644
index 00000000..ea7de352
--- /dev/null
+++ b/resources/icons/copy.svg
@@ -0,0 +1,8 @@
+
diff --git a/resources/icons/double_chat.svg b/resources/icons/double_chat.svg
new file mode 100644
index 00000000..0aaeeac3
--- /dev/null
+++ b/resources/icons/double_chat.svg
@@ -0,0 +1,10 @@
+
\ No newline at end of file
diff --git a/resources/icons/external_link.svg b/resources/icons/external_link.svg
new file mode 100644
index 00000000..37838221
--- /dev/null
+++ b/resources/icons/external_link.svg
@@ -0,0 +1,8 @@
+
diff --git a/resources/icons/forbidden.svg b/resources/icons/forbidden.svg
new file mode 100644
index 00000000..c1e69d5f
--- /dev/null
+++ b/resources/icons/forbidden.svg
@@ -0,0 +1,13 @@
+
+
+
\ No newline at end of file
diff --git a/resources/icons/go_back.svg b/resources/icons/go_back.svg
new file mode 100644
index 00000000..07c293cf
--- /dev/null
+++ b/resources/icons/go_back.svg
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/src/app.rs b/src/app.rs
index 605a7ca8..5f44fdee 100644
--- a/src/app.rs
+++ b/src/app.rs
@@ -7,6 +7,9 @@ live_design! {
import makepad_widgets::theme_desktop_dark::*;
import makepad_draw::shader::std::*;
+ import crate::shared::styles::*;
+ import crate::shared::clickable_view::ClickableView
+ import crate::shared::portal::*;
import crate::home::home_screen::HomeScreen
import crate::home::room_screen::RoomScreen
import crate::contacts::contacts_screen::ContactsScreen
@@ -16,9 +19,6 @@ live_design! {
import crate::profile::profile_screen::ProfileScreen
import crate::profile::my_profile_screen::MyProfileScreen
- import crate::shared::clickable_view::ClickableView
- import crate::shared::styles::*;
-
ICON_CHAT = dep("crate://self/resources/icons/chat.svg")
ICON_CONTACTS = dep("crate://self/resources/icons/contacts.svg")
ICON_DISCOVER = dep("crate://self/resources/icons/discover.svg")
@@ -184,75 +184,77 @@ live_design! {
}
}
- moments_stack_view = {
+ rooms_stack_view = {
header = {
content = {
title_container = {
+ padding: { bottom: 0 }
title = {
- text: "Moments"
+ width: Fit,
+ text: "Loading room..."
+ draw_text: {
+ color: (MESSAGE_TEXT_COLOR),
+ }
}
}
+ button_container = { left_button = {
+ icon_walk: {width: 12, height: 68},
+ } }
}
}
body = {
- {}
+ room_screen = {}
}
}
- add_contact_stack_view = {
+ moments_stack_view = {
header = {
content = {
title_container = {
title = {
- text: "Add Contact"
+ text: "Moments"
}
}
}
}
body = {
- {}
+ {}
}
}
- my_profile_stack_view = {
+ add_contact_stack_view = {
header = {
content = {
title_container = {
title = {
- text: "My Profile"
+ text: "Add Contact"
}
}
}
}
body = {
- {}
+ {}
}
}
- rooms_stack_view = {
+ my_profile_stack_view = {
header = {
content = {
title_container = {
- padding: { bottom: 0 }
title = {
- width: Fit,
- text: "Loading room..."
- draw_text: {
- color: (MESSAGE_TEXT_COLOR),
- }
+ text: "My Profile"
}
}
- button_container = { left_button = {
- icon_walk: {width: 12, height: 68},
- } }
}
}
body = {
- room_screen = {}
+ {}
}
}
- }
- }
+
+ } // end of StackNavigation
+
+ } // end of body
}
}
}
@@ -265,10 +267,8 @@ pub struct App {
ui: WidgetRef,
}
-impl LiveRegister for App {
- fn live_register(cx: &mut Cx) {
- makepad_widgets::live_design(cx);
+/*
// shared
crate::shared::styles::live_design(cx);
crate::shared::helpers::live_design(cx);
@@ -300,6 +300,21 @@ impl LiveRegister for App {
// profile
crate::profile::profile_screen::live_design(cx);
crate::profile::my_profile_screen::live_design(cx);
+
+*/
+
+impl LiveRegister for App {
+ fn live_register(cx: &mut Cx) {
+ // Order matters here, as some widget definitions depend on others.
+ // `makepad_widgets` must be registered first,
+ // then `shared`` widgets (in which styles are defined),
+ // then other modules widgets.
+ makepad_widgets::live_design(cx);
+ crate::shared::live_design(cx);
+ crate::home::live_design(cx);
+ crate::contacts::live_design(cx);
+ crate::discover::live_design(cx);
+ crate::profile::live_design(cx);
}
}
@@ -335,6 +350,7 @@ impl MatchEvent for App {
*/
fn handle_actions(&mut self, cx: &mut Cx, actions: &Actions) {
+ // Handle the user selecting a tab in the mobile menu on bottom.
self.ui.radio_button_set(ids!(
mobile_modes.tab1,
mobile_modes.tab2,
@@ -353,39 +369,30 @@ impl MatchEvent for App {
),
);
- self.handle_rooms_list_action(&actions);
-
- let mut navigation = self.ui.stack_navigation(id!(navigation));
- navigation.handle_stack_view_actions(cx, &actions);
- }
-}
+ // Handle stack navigation actions, e.g., navigating to/from a room screen
+ let mut stack_navigation = self.ui.stack_navigation(id!(navigation));
+ stack_navigation.handle_stack_view_actions(cx, &actions);
-impl AppMain for App {
- fn handle_event(&mut self, cx: &mut Cx, event: &Event) {
- // Forward events to the MatchEvent trait impl, and then to the App's UI element.
- self.match_event(cx, event);
- self.ui.handle_event(cx, event, &mut Scope::empty());
- }
-}
-impl App {
- fn handle_rooms_list_action(&mut self, actions: &Actions) {
for action in actions {
// Handle the user selecting a room to view (a RoomPreview in the RoomsList).
- if let RoomListAction::Selected { room_index: _, room_id, room_name } = action.as_widget_action().cast() {
- let stack_navigation = self.ui.stack_navigation(id!(navigation));
-
+ if let RoomListAction::Selected { room_index: _, room_id, room_name } = action.as_widget_action().cast() {
// Set the title of the RoomScreen's header to the room name.
- stack_navigation.set_title(
- live_id!(rooms_stack_view),
- &room_name.unwrap_or_else(|| format!("Room {}", &room_id)),
- );
-
+ let displayed_room_name = room_name.unwrap_or_else(|| format!("Room ID {}", &room_id));
+ stack_navigation.set_title(live_id!(rooms_stack_view), &displayed_room_name);
// Get a reference to the `RoomScreen` widget and tell it which room's data to show.
stack_navigation
.room_screen(id!(rooms_stack_view.room_screen))
- .set_displayed_room(room_id);
+ .set_displayed_room(displayed_room_name, room_id);
}
}
}
}
+
+impl AppMain for App {
+ fn handle_event(&mut self, cx: &mut Cx, event: &Event) {
+ // Forward events to the MatchEvent trait impl, and then to the App's UI element.
+ self.match_event(cx, event);
+ self.ui.handle_event(cx, event, &mut Scope::empty());
+ }
+}
diff --git a/src/contacts/mod.rs b/src/contacts/mod.rs
index 7bcd5ad1..4cf22f9b 100644
--- a/src/contacts/mod.rs
+++ b/src/contacts/mod.rs
@@ -1,5 +1,15 @@
+use makepad_widgets::Cx;
+
pub mod add_contact_screen;
pub mod contact_info;
pub mod contacts_group;
pub mod contacts_list;
pub mod contacts_screen;
+
+pub fn live_design(cx: &mut Cx) {
+ // Order matters here, as some widget definitions depend on others.
+ contacts_screen::live_design(cx);
+ contacts_group::live_design(cx);
+ contacts_list::live_design(cx);
+ add_contact_screen::live_design(cx);
+}
diff --git a/src/discover/mod.rs b/src/discover/mod.rs
index 0730a941..21fa660c 100644
--- a/src/discover/mod.rs
+++ b/src/discover/mod.rs
@@ -1,3 +1,12 @@
+use makepad_widgets::Cx;
+
pub mod discover_screen;
pub mod moments_screen;
pub mod moment_list;
+
+pub fn live_design(cx: &mut Cx) {
+ // Order matters here: moments_screen depends on moment_list.
+ discover_screen::live_design(cx);
+ moment_list::live_design(cx);
+ moments_screen::live_design(cx);
+}
diff --git a/src/home/mod.rs b/src/home/mod.rs
index d5e42cd2..0be8a62b 100644
--- a/src/home/mod.rs
+++ b/src/home/mod.rs
@@ -1,3 +1,11 @@
+use makepad_widgets::Cx;
+
+pub mod home_screen;
pub mod rooms_list;
pub mod room_screen;
-pub mod home_screen;
+
+pub fn live_design(cx: &mut Cx) {
+ home_screen::live_design(cx);
+ rooms_list::live_design(cx);
+ room_screen::live_design(cx);
+}
diff --git a/src/home/room_screen.rs b/src/home/room_screen.rs
index ba46dd67..002f4c80 100644
--- a/src/home/room_screen.rs
+++ b/src/home/room_screen.rs
@@ -12,16 +12,16 @@ use matrix_sdk::ruma::{
history_visibility::HistoryVisibility,
join_rules::JoinRule, message::{MessageFormat, MessageType, RoomMessageEventContent}, MediaSource,
}, AnySyncMessageLikeEvent, AnySyncTimelineEvent, FullStateEventContent, SyncMessageLikeEvent
- }, uint, MilliSecondsSinceUnixEpoch, OwnedRoomId,
+ }, uint, MilliSecondsSinceUnixEpoch, OwnedRoomId, RoomId,
};
use matrix_sdk_ui::timeline::{
self, AnyOtherFullStateEventContent, BundledReactions, EventTimelineItem, MemberProfileChange, MembershipChange, RoomMembershipChange, TimelineDetails, TimelineItem, TimelineItemContent, TimelineItemKind, VirtualTimelineItem
};
use rangemap::RangeSet;
-use unicode_segmentation::UnicodeSegmentation;
use crate::{
media_cache::{MediaCache, MediaCacheEntry, AVATAR_CACHE},
+ profile::user_profile::{ShowUserProfileAction, UserProfileInfo, UserProfileSlidingPaneWidgetExt},
shared::{avatar::{AvatarRef, AvatarWidgetRefExt}, html_or_plaintext::HtmlOrPlaintextWidgetRefExt, text_or_image::TextOrImageWidgetRefExt},
sliding_sync::{submit_async_request, take_timeline_update_receiver, MatrixRequest},
utils::{self, unix_time_millis_to_datetime, MediaFormatConst},
@@ -38,6 +38,7 @@ live_design! {
import crate::shared::avatar::Avatar;
import crate::shared::text_or_image::TextOrImage;
import crate::shared::html_or_plaintext::*;
+ import crate::profile::user_profile::UserProfileSlidingPane;
IMG_DEFAULT_AVATAR = dep("crate://self/resources/img/default_avatar.png")
ICO_FAV = dep("crate://self/resources/icon_favorite.svg")
@@ -66,8 +67,6 @@ live_design! {
COLOR_META = #xccc
COLOR_META_INV = #xfffa
COLOR_OVERLAY_BG = #x000000d8
- COLOR_DIVIDER = #x00000018
- COLOR_DIVIDER_DARK = #x00000044
COLOR_READ_MARKER = #xeb2733
COLOR_PROFILE_CIRCLE = #xfff8ee
@@ -119,15 +118,6 @@ live_design! {
padding: 9.0
text: ""
}
-
- LineH = {
- width: Fill,
- height: 2,
- margin: 0.0
- padding: 0.0,
- spacing: 0.0
- draw_bg: {color: (COLOR_DIVIDER)}
- }
Timestamp =