[gtkmm-documentation] examples: Replace Glib::Exception by Glib::Error



commit 6476e93f38e5302553972ba8550b698f62d1eddd
Author: Kjell Ahlstedt <kjellahlstedt gmail com>
Date:   Sat Dec 14 12:41:00 2019 +0100

    examples: Replace Glib::Exception by Glib::Error
    
    Glib::Exception has been removed. See glibmm#23.

 examples/book/giomm/directory_list/main.cc  | 2 +-
 examples/book/giomm/read_file/main.cc       | 2 +-
 examples/book/giomm/read_file_async/main.cc | 6 +++---
 examples/book/giomm/volumes/main.cc         | 2 +-
 examples/book/giomm/write_file/main.cc      | 2 +-
 5 files changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/examples/book/giomm/directory_list/main.cc b/examples/book/giomm/directory_list/main.cc
index 0ffc9bb..4fad9b3 100644
--- a/examples/book/giomm/directory_list/main.cc
+++ b/examples/book/giomm/directory_list/main.cc
@@ -42,7 +42,7 @@ int main(int /* argc */, char** /* argv */)
     }
 
   }
-  catch(const Glib::Exception& ex)
+  catch(const Glib::Error& ex)
   {
     std::cerr << "Exception caught: " << ex.what() << std::endl;
   }
diff --git a/examples/book/giomm/read_file/main.cc b/examples/book/giomm/read_file/main.cc
index 4fb4645..398b3fb 100644
--- a/examples/book/giomm/read_file/main.cc
+++ b/examples/book/giomm/read_file/main.cc
@@ -45,7 +45,7 @@ int main(int /* argc */, char** /* argv */)
       std::cerr << "Gio::InputStream::read() read 0 bytes." << std::endl;
 
   }
-  catch(const Glib::Exception& ex)
+  catch(const Glib::Error& ex)
   {
     std::cerr << "Exception caught: " << ex.what() << std::endl;
   }
diff --git a/examples/book/giomm/read_file_async/main.cc b/examples/book/giomm/read_file_async/main.cc
index 93d7e41..10c327c 100644
--- a/examples/book/giomm/read_file_async/main.cc
+++ b/examples/book/giomm/read_file_async/main.cc
@@ -41,7 +41,7 @@ void on_stream_read_async_ready(Glib::RefPtr<Gio::AsyncResult>& result)
       std::cerr << "Gio::InputStream::read() read 0 bytes." << std::endl;
 
   }
-  catch(const Glib::Exception& ex)
+  catch(const Glib::Error& ex)
   {
     std::cerr << "Exception caught: " << ex.what() << std::endl;
   }
@@ -59,7 +59,7 @@ void on_file_read_async_ready(Glib::RefPtr<Gio::AsyncResult>& result)
     if(!stream)
       std::cerr << "Gio::File::read() returned an empty RefPtr." << std::endl;
   }
-  catch(const Glib::Exception& ex)
+  catch(const Glib::Error& ex)
   {
     std::cerr << "Exception caught: " << ex.what() << std::endl;
     mainloop->quit();
@@ -82,7 +82,7 @@ int main(int /* argc */, char** /* argv */)
     if(!file)
       std::cerr << "Gio::File::create_for_path() returned an empty RefPtr." << std::endl;
   }
-  catch(const Glib::Exception& ex)
+  catch(const Glib::Error& ex)
   {
     std::cerr << "Exception caught: " << ex.what() << std::endl;
   }
diff --git a/examples/book/giomm/volumes/main.cc b/examples/book/giomm/volumes/main.cc
index e403700..2032d0e 100644
--- a/examples/book/giomm/volumes/main.cc
+++ b/examples/book/giomm/volumes/main.cc
@@ -24,7 +24,7 @@ int main(int /* argc */, char** /* argv */)
       }
     }
   }
-  catch(const Glib::Exception& ex)
+  catch(const Glib::Error& ex)
   {
     std::cerr << "Exception caught: " << ex.what() << std::endl;
   }
diff --git a/examples/book/giomm/write_file/main.cc b/examples/book/giomm/write_file/main.cc
index cc725b1..c6811c0 100644
--- a/examples/book/giomm/write_file/main.cc
+++ b/examples/book/giomm/write_file/main.cc
@@ -58,7 +58,7 @@ int main(int /* argc */, char** /* argv */)
     stream->close();
     stream.reset(); //Stream can't be used after we have closed it.
   }
-  catch(const Glib::Exception& ex)
+  catch(const Glib::Error& ex)
   {
     std::cerr << "Exception caught: " << ex.what() << std::endl;
   }


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