Skip to content

Commit

Permalink
Merge remote-tracking branch 'bushmann/feature/broadcast-relay-list-b…
Browse files Browse the repository at this point in the history
…utton' into unstable
  • Loading branch information
mikedilger committed Sep 24, 2023
2 parents 343aec4 + ec7563c commit fb9b56a
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions src/ui/relays/mine.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,16 @@ pub(super) fn update(app: &mut GossipUi, _ctx: &Context, _frame: &mut eframe::Fr
ui.horizontal_wrapped(|ui| {
ui.heading(Page::RelaysMine.name());
ui.set_enabled(!is_editing);
ui.add_space(10.0);
if ui.button("Advertise Relay List")
.on_hover_text("Advertise my relays. Will send 10002 kind to all relays that have 'ADVERTISE' usage enabled")
.clicked() {
let _ = GLOBALS
.to_overlord
.send(ToOverlordMessage::AdvertiseRelayList);
}
ui.add_space(50.0);
widgets::search_filter_field(ui, &mut app.relays.search, 200.0);
ui.with_layout(egui::Layout::right_to_left(egui::Align::Min), |ui| {
ui.add_space(20.0);
super::configure_list_btn(app, ui);
Expand All @@ -26,14 +36,6 @@ pub(super) fn update(app: &mut GossipUi, _ctx: &Context, _frame: &mut eframe::Fr
});
ui.add_space(10.0);

ui.horizontal(|ui| {
if ui.button("↑ Advertise Relay List ↑").clicked() {
let _ = GLOBALS
.to_overlord
.send(ToOverlordMessage::AdvertiseRelayList);
}
});

let relays = if !is_editing {
// clear edit cache if present
if !app.relays.edit_relays.is_empty() {
Expand Down

0 comments on commit fb9b56a

Please sign in to comment.