[gnote] Update readonly after popover changes
- From: Aurimas Černius <aurimasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnote] Update readonly after popover changes
- Date: Sun, 31 Mar 2019 16:07:41 +0000 (UTC)
commit d5dd1aa7330ac4239196830897239c91f4f60fd0
Author: Aurimas Černius <aurisc4 gmail com>
Date: Sun Mar 31 18:06:14 2019 +0300
Update readonly after popover changes
src/addins/readonly/readonly.desktop.in.in | 2 +-
src/addins/readonly/readonlynoteaddin.cpp | 6 +++---
src/addins/readonly/readonlynoteaddin.hpp | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/src/addins/readonly/readonly.desktop.in.in b/src/addins/readonly/readonly.desktop.in.in
index 0fa5f7df..ad7cb5a4 100644
--- a/src/addins/readonly/readonly.desktop.in.in
+++ b/src/addins/readonly/readonly.desktop.in.in
@@ -4,7 +4,7 @@ _Name=Read Only
_Description=Mark certain notes as read only
_Authors=Aurimas Černius, Debarshi Ray and Arief Bayu Purwanto
Category=Tools
-Version=0.2
+Version=0.3
DefaultEnabled=false
Module=libreadonly
LibgnoteRelease=@LIBGNOTE_RELEASE@
diff --git a/src/addins/readonly/readonlynoteaddin.cpp b/src/addins/readonly/readonlynoteaddin.cpp
index 5a9d81fe..70a27350 100644
--- a/src/addins/readonly/readonlynoteaddin.cpp
+++ b/src/addins/readonly/readonlynoteaddin.cpp
@@ -1,7 +1,7 @@
/*
* gnote
*
- * Copyright (C) 2013,2016 Aurimas Cernius
+ * Copyright (C) 2013,2016,2019 Aurimas Cernius
* Copyright (C) 2010 Debarshi Ray
*
* This program is free software: you can redistribute it and/or modify
@@ -63,11 +63,11 @@ void ReadOnlyNoteAddin::on_note_opened()
get_window()->signal_backgrounded.connect(sigc::mem_fun(*this, &ReadOnlyNoteAddin::on_background));
}
-std::map<int, Gtk::Widget*> ReadOnlyNoteAddin::get_actions_popover_widgets() const
+std::vector<gnote::PopoverWidget> ReadOnlyNoteAddin::get_actions_popover_widgets() const
{
auto widgets = NoteAddin::get_actions_popover_widgets();
auto button = gnote::utils::create_popover_button("win.readonly-toggle", _("Read Only"));
- gnote::utils::add_item_to_ordered_map(widgets, gnote::READ_ONLY_ORDER, button);
+ widgets.push_back(gnote::PopoverWidget::create_for_note(gnote::READ_ONLY_ORDER, button));
return widgets;
}
diff --git a/src/addins/readonly/readonlynoteaddin.hpp b/src/addins/readonly/readonlynoteaddin.hpp
index 27615d2b..cfce8e49 100644
--- a/src/addins/readonly/readonlynoteaddin.hpp
+++ b/src/addins/readonly/readonlynoteaddin.hpp
@@ -1,7 +1,7 @@
/*
* gnote
*
- * Copyright (C) 2013,2016 Aurimas Cernius
+ * Copyright (C) 2013,2016,2019 Aurimas Cernius
* Copyright (C) 2010 Debarshi Ray
*
* This program is free software: you can redistribute it and/or modify
@@ -47,7 +47,7 @@ public:
virtual void initialize() override;
virtual void shutdown() override;
virtual void on_note_opened() override;
- virtual std::map<int, Gtk::Widget*> get_actions_popover_widgets() const override;
+ virtual std::vector<gnote::PopoverWidget> get_actions_popover_widgets() const override;
private:
ReadOnlyNoteAddin();
void on_menu_item_toggled(const Glib::VariantBase & state);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]