// This file Copyright © Transmission authors and contributors. // It may be used under the MIT (SPDX: MIT) license. // License text can be found in the licenses/ folder. #pragma once #include #include #include #include #include #include #include class Session; class Torrent; class MainWindow : public Gtk::ApplicationWindow { public: MainWindow( BaseObjectType* cast_item, Glib::RefPtr const& builder, Gtk::Application& app, Glib::RefPtr const& actions, Glib::RefPtr const& core); ~MainWindow() override; TR_DISABLE_COPY_MOVE(MainWindow) static std::unique_ptr create( Gtk::Application& app, Glib::RefPtr const& actions, Glib::RefPtr const& core); void for_each_selected_torrent(std::function const&)> const& callback) const; bool for_each_selected_torrent_until(std::function const&)> const& callback) const; void select_all(); void unselect_all(); void set_busy(bool isBusy); void refresh(); sigc::signal& signal_selection_changed(); private: class Impl; std::unique_ptr const impl_; };