[gnote] Preparetion for move semantic addition



commit 0e8042a056a40588b22f9ecc3823daea5954f270
Author: Aurimas Černius <aurisc4 gmail com>
Date:   Sun May 29 18:52:40 2022 +0300

    Preparetion for move semantic addition

 src/dbus/remotecontrol.cpp                           | 2 +-
 src/plugins/noteoftheday/noteofthedaypreferences.cpp | 7 ++-----
 src/synchronization/syncmanager.cpp                  | 4 ++--
 src/watchers.cpp                                     | 2 +-
 4 files changed, 6 insertions(+), 9 deletions(-)
---
diff --git a/src/dbus/remotecontrol.cpp b/src/dbus/remotecontrol.cpp
index 62c710c2..1a336cf4 100644
--- a/src/dbus/remotecontrol.cpp
+++ b/src/dbus/remotecontrol.cpp
@@ -76,7 +76,7 @@ namespace gnote {
       return "";
 
     try {
-      note = m_manager.create (linked_title);
+      note = m_manager.create(Glib::ustring(linked_title));
       return note->uri();
     } 
     catch (const std::exception & e) {
diff --git a/src/plugins/noteoftheday/noteofthedaypreferences.cpp 
b/src/plugins/noteoftheday/noteofthedaypreferences.cpp
index 9c3be4a0..99289ce1 100644
--- a/src/plugins/noteoftheday/noteofthedaypreferences.cpp
+++ b/src/plugins/noteoftheday/noteofthedaypreferences.cpp
@@ -1,7 +1,7 @@
 /*
  * gnote
  *
- * Copyright (C) 2011-2014,2019 Aurimas Cernius
+ * Copyright (C) 2011-2014,2019,2022 Aurimas Cernius
  * Copyright (C) 2009 Debarshi Ray
  *
  * This program is free software: you can redistribute it and/or modify
@@ -62,10 +62,7 @@ void NoteOfTheDayPreferences::open_template_button_clicked() const
 
   if (0 == template_note) {
     try {
-      template_note = m_note_manager.create(
-                                NoteOfTheDay::s_template_title,
-                                NoteOfTheDay::get_template_content(
-                                  NoteOfTheDay::s_template_title));
+      template_note = m_note_manager.create(Glib::ustring(NoteOfTheDay::s_template_title), 
NoteOfTheDay::get_template_content(NoteOfTheDay::s_template_title));
       template_note->queue_save(gnote::CONTENT_CHANGED);
     }
     catch (const sharp::Exception & e) {
diff --git a/src/synchronization/syncmanager.cpp b/src/synchronization/syncmanager.cpp
index 982b2c9e..0fdc013f 100644
--- a/src/synchronization/syncmanager.cpp
+++ b/src/synchronization/syncmanager.cpp
@@ -1,7 +1,7 @@
 /*
  * gnote
  *
- * Copyright (C) 2012-2014,2017,2019-2021 Aurimas Cernius
+ * Copyright (C) 2012-2014,2017,2019-2022 Aurimas Cernius
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -705,7 +705,7 @@ namespace sync {
   void SyncManager::create_note(const NoteUpdate & noteUpdate)
   {
     try {
-      NoteBase::Ptr existingNote = note_mgr().create_with_guid(noteUpdate.m_title, noteUpdate.m_uuid);
+      NoteBase::Ptr existingNote = note_mgr().create_with_guid(Glib::ustring(noteUpdate.m_title), 
Glib::ustring(noteUpdate.m_uuid));
       update_local_note(existingNote, noteUpdate, DOWNLOAD_NEW);
     }
     catch(std::exception & e) {
diff --git a/src/watchers.cpp b/src/watchers.cpp
index 2252f80b..2168727f 100644
--- a/src/watchers.cpp
+++ b/src/watchers.cpp
@@ -1065,7 +1065,7 @@ namespace gnote {
     if (!link) {
       DBG_OUT("Creating note '%s'...", link_name.c_str());
       try {
-        link = manager().create (link_name);
+        link = manager().create(Glib::ustring(link_name));
       } 
       catch(...)
       {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]