diff --git a/libaegisub/ass/dialogue_parser.cpp b/libaegisub/ass/dialogue_parser.cpp index 95f4b41e1..045f88946 100644 --- a/libaegisub/ass/dialogue_parser.cpp +++ b/libaegisub/ass/dialogue_parser.cpp @@ -18,9 +18,9 @@ #include "libaegisub/spellchecker.h" -#include "iconv.h" - -#include +#include +#include +#include namespace { diff --git a/libaegisub/common/cajun/elements.cpp b/libaegisub/common/cajun/elements.cpp index cfd569973..c38b08317 100644 --- a/libaegisub/common/cajun/elements.cpp +++ b/libaegisub/common/cajun/elements.cpp @@ -9,8 +9,7 @@ Author: Terry Caton #include "libaegisub/cajun/visitor.h" -#include -#include +#include namespace { using namespace json; diff --git a/libaegisub/common/calltip_provider.cpp b/libaegisub/common/calltip_provider.cpp index 63cf2b54f..6d1671899 100644 --- a/libaegisub/common/calltip_provider.cpp +++ b/libaegisub/common/calltip_provider.cpp @@ -18,8 +18,6 @@ #include "libaegisub/ass/dialogue_parser.h" -#include - namespace { struct proto_lit { const char *name; diff --git a/libaegisub/common/charset.cpp b/libaegisub/common/charset.cpp index ec5bab238..02abfcc24 100644 --- a/libaegisub/common/charset.cpp +++ b/libaegisub/common/charset.cpp @@ -28,7 +28,6 @@ #include "../../vendor/universalchardet/nscore.h" #include "../../vendor/universalchardet/nsUniversalDetector.h" -#include "../../vendor/universalchardet/nsMBCSGroupProber.h" #include "../../vendor/universalchardet/nsCharSetProber.h" namespace { diff --git a/libaegisub/common/charset_6937.cpp b/libaegisub/common/charset_6937.cpp index f796993a6..c0e446a14 100644 --- a/libaegisub/common/charset_6937.cpp +++ b/libaegisub/common/charset_6937.cpp @@ -18,12 +18,10 @@ #include "charset_6937.h" -#include #include - #include -#include +#include namespace { diff --git a/libaegisub/common/file_mapping.cpp b/libaegisub/common/file_mapping.cpp index 5462fff1e..e12ed1106 100644 --- a/libaegisub/common/file_mapping.cpp +++ b/libaegisub/common/file_mapping.cpp @@ -20,7 +20,7 @@ #include "libaegisub/make_unique.h" #include "libaegisub/util.h" -#include +#include #include #include diff --git a/libaegisub/common/fs.cpp b/libaegisub/common/fs.cpp index 6d7d71452..2d5fdee06 100644 --- a/libaegisub/common/fs.cpp +++ b/libaegisub/common/fs.cpp @@ -17,12 +17,11 @@ #include "libaegisub/fs.h" #include "libaegisub/access.h" -#include "libaegisub/exception.h" #include "libaegisub/log.h" #include #define BOOST_NO_SCOPED_ENUMS -#include +#include #undef BOOST_NO_SCOPED_ENUMS namespace bfs = boost::filesystem; diff --git a/libaegisub/common/hotkey.cpp b/libaegisub/common/hotkey.cpp index 4a527e7c8..abe6cc346 100644 --- a/libaegisub/common/hotkey.cpp +++ b/libaegisub/common/hotkey.cpp @@ -19,7 +19,6 @@ #include "libaegisub/hotkey.h" #include "libaegisub/cajun/writer.h" -#include "libaegisub/exception.h" #include "libaegisub/io.h" #include "libaegisub/json.h" #include "libaegisub/log.h" @@ -27,7 +26,6 @@ #include #include #include -#include #include namespace agi { diff --git a/libaegisub/common/io.cpp b/libaegisub/common/io.cpp index 0892b0f44..c95c5559a 100644 --- a/libaegisub/common/io.cpp +++ b/libaegisub/common/io.cpp @@ -22,11 +22,10 @@ #include "libaegisub/fs.h" #include "libaegisub/log.h" #include "libaegisub/make_unique.h" -#include "libaegisub/path.h" #include "libaegisub/util.h" -#include #include +#include namespace agi { namespace io { diff --git a/libaegisub/common/json.cpp b/libaegisub/common/json.cpp index 556498b86..d1fd1613e 100644 --- a/libaegisub/common/json.cpp +++ b/libaegisub/common/json.cpp @@ -18,10 +18,10 @@ #include "libaegisub/json.h" +#include "libaegisub/cajun/reader.h" #include "libaegisub/fs.h" #include "libaegisub/io.h" #include "libaegisub/log.h" -#include "libaegisub/make_unique.h" #include diff --git a/libaegisub/common/keyframe.cpp b/libaegisub/common/keyframe.cpp index 98b7ee15f..50e537338 100644 --- a/libaegisub/common/keyframe.cpp +++ b/libaegisub/common/keyframe.cpp @@ -19,13 +19,11 @@ #include "libaegisub/keyframe.h" -#include - #include "libaegisub/io.h" #include "libaegisub/line_iterator.h" #include -#include +#include namespace { std::vector agi_keyframes(std::istream &file) { diff --git a/libaegisub/common/log.cpp b/libaegisub/common/log.cpp index 7c59b288a..70817f33b 100644 --- a/libaegisub/common/log.cpp +++ b/libaegisub/common/log.cpp @@ -12,25 +12,18 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -/// @file log.cpp -/// @brief Logging -/// @ingroup libaegisub - #include "libaegisub/log.h" #include "libaegisub/cajun/elements.h" #include "libaegisub/cajun/writer.h" #include "libaegisub/dispatch.h" -#include "libaegisub/io.h" +#include "libaegisub/time.h" #include "libaegisub/util.h" -#include -#include #include -#include -#include -#include -#include +#include +#include +#include namespace agi { namespace log { diff --git a/libaegisub/common/option.cpp b/libaegisub/common/option.cpp index 59bad38c0..b28cf3c58 100644 --- a/libaegisub/common/option.cpp +++ b/libaegisub/common/option.cpp @@ -30,7 +30,6 @@ #include "option_visit.h" #include -#include #include #include diff --git a/libaegisub/common/option_visit.cpp b/libaegisub/common/option_visit.cpp index 825f19571..12716394d 100644 --- a/libaegisub/common/option_visit.cpp +++ b/libaegisub/common/option_visit.cpp @@ -20,9 +20,7 @@ #include "option_visit.h" #include -#include -#include #include #include #include diff --git a/libaegisub/common/option_visit.h b/libaegisub/common/option_visit.h index 48988c0e1..a53bf3bd0 100644 --- a/libaegisub/common/option_visit.h +++ b/libaegisub/common/option_visit.h @@ -22,7 +22,6 @@ #include "libaegisub/cajun/visitor.h" #include -#include namespace agi { diff --git a/libaegisub/common/path.cpp b/libaegisub/common/path.cpp index 154fc2dd3..05f1fd74f 100644 --- a/libaegisub/common/path.cpp +++ b/libaegisub/common/path.cpp @@ -21,10 +21,8 @@ #include "libaegisub/path.h" #include "libaegisub/fs.h" -#include "libaegisub/make_unique.h" #include -#include #include namespace { diff --git a/libaegisub/common/thesaurus.cpp b/libaegisub/common/thesaurus.cpp index c26cd3d2b..111f6af87 100644 --- a/libaegisub/common/thesaurus.cpp +++ b/libaegisub/common/thesaurus.cpp @@ -23,7 +23,7 @@ #include "libaegisub/line_iterator.h" #include "libaegisub/make_unique.h" -#include +#include #include #include #include diff --git a/libaegisub/common/util.cpp b/libaegisub/common/util.cpp index 6485d6828..18d14a8a3 100644 --- a/libaegisub/common/util.cpp +++ b/libaegisub/common/util.cpp @@ -17,11 +17,9 @@ #include "libaegisub/util.h" #include "libaegisub/util_osx.h" -#include "libaegisub/exception.h" - #include #include -#include +#include #include namespace { diff --git a/libaegisub/common/vfr.cpp b/libaegisub/common/vfr.cpp index f03947c4c..972655660 100644 --- a/libaegisub/common/vfr.cpp +++ b/libaegisub/common/vfr.cpp @@ -21,7 +21,6 @@ #include "libaegisub/charset.h" #include "libaegisub/io.h" #include "libaegisub/line_iterator.h" -#include "libaegisub/scoped_ptr.h" #include #include @@ -30,7 +29,6 @@ #include #include #include -#include namespace { diff --git a/libaegisub/include/libaegisub/access.h b/libaegisub/include/libaegisub/access.h index f58d2d0fa..f956cc920 100644 --- a/libaegisub/include/libaegisub/access.h +++ b/libaegisub/include/libaegisub/access.h @@ -12,16 +12,9 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -/// @file access.h -/// @brief Public interface for access methods. -/// @ingroup libaegisub - -#include #include -namespace agi { - namespace acs { - +namespace agi { namespace acs { enum Type { FileRead, DirRead, @@ -36,6 +29,4 @@ inline void CheckFileWrite(fs::path const& file) { Check(file, acs::FileWrite); inline void CheckDirRead(fs::path const& dir) { Check(dir, acs::DirRead); } inline void CheckDirWrite(fs::path const& dir) { Check(dir, acs::DirWrite); } - - } // namespace axs -} // namespace agi +} } diff --git a/libaegisub/include/libaegisub/cajun/elements.h b/libaegisub/include/libaegisub/cajun/elements.h index 63688a07f..9595be9a1 100644 --- a/libaegisub/include/libaegisub/cajun/elements.h +++ b/libaegisub/include/libaegisub/cajun/elements.h @@ -10,7 +10,6 @@ Author: Terry Caton #include #include -#include #include #include #include @@ -25,9 +24,6 @@ struct Visitor; struct ConstVisitor; class UnknownElement; -template -class TrivialType_T; - typedef int64_t Integer; typedef double Double; typedef bool Boolean; diff --git a/libaegisub/include/libaegisub/hotkey.h b/libaegisub/include/libaegisub/hotkey.h index a520d6e6c..f7e663161 100644 --- a/libaegisub/include/libaegisub/hotkey.h +++ b/libaegisub/include/libaegisub/hotkey.h @@ -18,7 +18,6 @@ #include #include -#include #include #include diff --git a/libaegisub/include/libaegisub/json.h b/libaegisub/include/libaegisub/json.h index 1061df486..cad86fd9c 100644 --- a/libaegisub/include/libaegisub/json.h +++ b/libaegisub/include/libaegisub/json.h @@ -16,14 +16,10 @@ /// @brief Parse JSON files and return json::UnknownElement /// @ingroup libaegisub io -#include #include #include -#include - -namespace agi { - namespace json_util { +namespace agi { namespace json_util { /// Parse a JSON stream. /// @param stream JSON stream to parse @@ -41,5 +37,4 @@ json::UnknownElement file(agi::fs::path const& file); /// @return json::UnknownElement json::UnknownElement file(agi::fs::path const& file, std::pair default_config); - } // namespace json_util -} // namespace agi +} } diff --git a/libaegisub/include/libaegisub/kana_table.h b/libaegisub/include/libaegisub/kana_table.h index a826819be..1a25c098f 100644 --- a/libaegisub/include/libaegisub/kana_table.h +++ b/libaegisub/include/libaegisub/kana_table.h @@ -14,7 +14,8 @@ // // Aegisub Project http://www.aegisub.org/ -#include +#include +#include #include namespace agi { diff --git a/libaegisub/include/libaegisub/keyframe.h b/libaegisub/include/libaegisub/keyframe.h index 812b98469..8f0eb459f 100644 --- a/libaegisub/include/libaegisub/keyframe.h +++ b/libaegisub/include/libaegisub/keyframe.h @@ -12,18 +12,12 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -/// @file keyframe.h -/// @see keyframe.cpp -/// @ingroup libaegisub -/// - #include #include "exception.h" #include "fs_fwd.h" namespace agi { - namespace vfr { class Framerate; } namespace keyframe { /// @brief Load a keyframe file /// @param filename File to load diff --git a/libaegisub/include/libaegisub/log.h b/libaegisub/include/libaegisub/log.h index f2c6b75f7..21b7eb026 100644 --- a/libaegisub/include/libaegisub/log.h +++ b/libaegisub/include/libaegisub/log.h @@ -19,7 +19,6 @@ #include #include -#include #include #include #include diff --git a/libaegisub/include/libaegisub/path.h b/libaegisub/include/libaegisub/path.h index cbb10f529..73398c5af 100644 --- a/libaegisub/include/libaegisub/path.h +++ b/libaegisub/include/libaegisub/path.h @@ -18,7 +18,6 @@ /// @brief Common paths. /// @ingroup libaegisub -#include #include #include diff --git a/libaegisub/include/libaegisub/thesaurus.h b/libaegisub/include/libaegisub/thesaurus.h index 3630321cf..887d59b13 100644 --- a/libaegisub/include/libaegisub/thesaurus.h +++ b/libaegisub/include/libaegisub/thesaurus.h @@ -12,10 +12,6 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -/// @file thesaurus.h -/// @brief MyThes-compatible thesaurus implementation -/// @ingroup libaegisub thesaurus - #include "fs_fwd.h" #include diff --git a/libaegisub/include/libaegisub/util.h b/libaegisub/include/libaegisub/util.h index 46ea888a3..972e57334 100644 --- a/libaegisub/include/libaegisub/util.h +++ b/libaegisub/include/libaegisub/util.h @@ -12,17 +12,11 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -/// @file util.h -/// @brief Public interface for general utilities. -/// @ingroup libaegisub - #include #include #include -#include #include -#include struct tm; diff --git a/libaegisub/include/libaegisub/vfr.h b/libaegisub/include/libaegisub/vfr.h index d38edfdac..b5d0da968 100644 --- a/libaegisub/include/libaegisub/vfr.h +++ b/libaegisub/include/libaegisub/vfr.h @@ -12,16 +12,10 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -/// @file vfr.h -/// @brief Framerate handling of all sorts -/// @ingroup libaegisub video_input - #pragma once -#include -#include - #include +#include #include #include diff --git a/libaegisub/lua/modules/lfs.cpp b/libaegisub/lua/modules/lfs.cpp index 7b3153beb..c6a554dfe 100644 --- a/libaegisub/lua/modules/lfs.cpp +++ b/libaegisub/lua/modules/lfs.cpp @@ -16,7 +16,8 @@ #include "libaegisub/lua/utils.h" -#include +#include +#include #include namespace { diff --git a/libaegisub/lua/modules/unicode.cpp b/libaegisub/lua/modules/unicode.cpp index 66b955497..7c8deb3a9 100644 --- a/libaegisub/lua/modules/unicode.cpp +++ b/libaegisub/lua/modules/unicode.cpp @@ -16,7 +16,7 @@ #include "libaegisub/lua/utils.h" -#include +#include namespace { using namespace agi::lua; diff --git a/libaegisub/unix/fs.cpp b/libaegisub/unix/fs.cpp index b5f6af139..8f6ead6a8 100644 --- a/libaegisub/unix/fs.cpp +++ b/libaegisub/unix/fs.cpp @@ -18,7 +18,8 @@ #include "libaegisub/fs.h" #include "libaegisub/io.h" -#include +#include +#include #include #include #include diff --git a/libaegisub/unix/log.cpp b/libaegisub/unix/log.cpp index 4840f8240..0e137804b 100644 --- a/libaegisub/unix/log.cpp +++ b/libaegisub/unix/log.cpp @@ -12,22 +12,14 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -/// @file log.cpp -/// @brief Unix logging -/// @ingroup libaegisub - #include #include -#include #include #include "libaegisub/log.h" -#include "libaegisub/make_unique.h" - -namespace agi { - namespace log { +namespace agi { namespace log { void EmitSTDOUT::log(SinkMessage *sm) { tm tmtime; localtime_r(&sm->tv.tv_sec, &tmtime); @@ -47,6 +39,4 @@ void EmitSTDOUT::log(SinkMessage *sm) { if (!isatty(fileno(stdout))) fflush(stdout); } - - } // namespace log -} // namespace agi +} } diff --git a/libaegisub/unix/path.cpp b/libaegisub/unix/path.cpp index 8fd082f53..761233177 100644 --- a/libaegisub/unix/path.cpp +++ b/libaegisub/unix/path.cpp @@ -16,9 +16,10 @@ #include +#include #include -#include +#include #include namespace { @@ -38,7 +39,6 @@ std::string home_dir() { } namespace agi { - void Path::FillPlatformSpecificPaths() { #ifndef __APPLE__ agi::fs::path home = home_dir(); diff --git a/libaegisub/unix/util.cpp b/libaegisub/unix/util.cpp index 80a76a859..32ca827f2 100644 --- a/libaegisub/unix/util.cpp +++ b/libaegisub/unix/util.cpp @@ -12,12 +12,6 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -/// @file util.cpp -/// @brief Unix utility methods. -/// @ingroup libaegisub unix - -#include "libaegisub/make_unique.h" - #include namespace agi { namespace util { diff --git a/libaegisub/windows/path_win.cpp b/libaegisub/windows/path_win.cpp index 2c8fc60bd..9784a9454 100644 --- a/libaegisub/windows/path_win.cpp +++ b/libaegisub/windows/path_win.cpp @@ -20,6 +20,7 @@ #include +#include #include #include diff --git a/src/ass_attachment.h b/src/ass_attachment.h index 4f42b4085..34416d674 100644 --- a/src/ass_attachment.h +++ b/src/ass_attachment.h @@ -19,7 +19,6 @@ #include #include -#include /// @class AssAttachment class AssAttachment final : public AssEntry { diff --git a/src/ass_dialogue.h b/src/ass_dialogue.h index 996586a50..a008b1516 100644 --- a/src/ass_dialogue.h +++ b/src/ass_dialogue.h @@ -36,8 +36,6 @@ #include "ass_override.h" #include "ass_time.h" -#include - #include #include #include diff --git a/src/ass_exporter.h b/src/ass_exporter.h index 6c2670046..1565c01f2 100644 --- a/src/ass_exporter.h +++ b/src/ass_exporter.h @@ -39,7 +39,6 @@ #include class AssExportFilter; -class AssFile; namespace agi { struct Context; } class wxSizer; class wxWindow; diff --git a/src/ass_file.cpp b/src/ass_file.cpp index 8397ff132..e5090ec02 100644 --- a/src/ass_file.cpp +++ b/src/ass_file.cpp @@ -22,9 +22,6 @@ #include "ass_style.h" #include "ass_style_storage.h" #include "options.h" -#include "utils.h" - -#include #include #include diff --git a/src/ass_karaoke.cpp b/src/ass_karaoke.cpp index 751a65441..7d9c100f0 100644 --- a/src/ass_karaoke.cpp +++ b/src/ass_karaoke.cpp @@ -17,14 +17,10 @@ #include "ass_karaoke.h" #include "ass_dialogue.h" -#include "ass_file.h" -#include "include/aegisub/context.h" -#include "selection_controller.h" #include #include #include -#include std::string AssKaraoke::Syllable::GetText(bool k_tag) const { std::string ret; diff --git a/src/ass_karaoke.h b/src/ass_karaoke.h index 4cbcdcdb7..fd929f867 100644 --- a/src/ass_karaoke.h +++ b/src/ass_karaoke.h @@ -15,7 +15,6 @@ // Aegisub Project http://www.aegisub.org/ #include -#include #include #include diff --git a/src/ass_parser.h b/src/ass_parser.h index 41396fb1f..9cf6f5017 100644 --- a/src/ass_parser.h +++ b/src/ass_parser.h @@ -12,8 +12,6 @@ // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -#include -#include #include class AssAttachment; diff --git a/src/ass_style.cpp b/src/ass_style.cpp index 21efc713f..0fd93413b 100644 --- a/src/ass_style.cpp +++ b/src/ass_style.cpp @@ -39,12 +39,9 @@ #include -#include #include #include #include -#include - #include AssStyle::AssStyle() { diff --git a/src/ass_style.h b/src/ass_style.h index 4ce0fccdd..1ec57073e 100644 --- a/src/ass_style.h +++ b/src/ass_style.h @@ -27,17 +27,13 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file ass_style.h -/// @see ass_style.cpp -/// @ingroup subs_storage -/// - #include "ass_entry.h" #include #include -#include + +class wxArrayString; class AssStyle final : public AssEntry, public AssEntryListHook { std::string data; diff --git a/src/async_video_provider.cpp b/src/async_video_provider.cpp index b57ff95c0..6f2765de3 100644 --- a/src/async_video_provider.cpp +++ b/src/async_video_provider.cpp @@ -20,15 +20,10 @@ #include "ass_file.h" #include "export_fixstyle.h" #include "include/aegisub/subtitles_provider.h" -#include "video_frame.h" #include "video_provider_manager.h" #include -#include -#include -#include - enum { NEW_SUBS_FILE = -1, SUBS_FILE_ALREADY_LOADED = -2 diff --git a/src/audio_box.cpp b/src/audio_box.cpp index 61947d910..cf9230e6f 100644 --- a/src/audio_box.cpp +++ b/src/audio_box.cpp @@ -27,28 +27,6 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_box.cpp -/// @brief The entire audio area in the main UI, containing display and related toolbars -/// @ingroup audio_ui -/// - -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include // Keep this last so wxSW_3D is set. - -#include - #include "audio_box.h" #include "include/aegisub/context.h" @@ -58,14 +36,20 @@ #include "audio_display.h" #include "audio_karaoke.h" #include "audio_timing.h" -#include "command/command.h" -#include "libresrc/libresrc.h" #include "options.h" #include "project.h" #include "toggle_bitmap.h" -#include "selection_controller.h" #include "utils.h" +#include +#include +#include +#include +#include +#include +#include +#include + enum { Audio_Horizontal_Zoom = 1600, Audio_Vertical_Zoom, diff --git a/src/audio_box.h b/src/audio_box.h index a449ddc31..ea633eba7 100644 --- a/src/audio_box.h +++ b/src/audio_box.h @@ -27,11 +27,7 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_box.h -/// @see audio_box.cpp -/// @ingroup audio_ui -/// - +#include #include #include diff --git a/src/audio_colorscheme.cpp b/src/audio_colorscheme.cpp index d8fb74127..bbcd7763e 100644 --- a/src/audio_colorscheme.cpp +++ b/src/audio_colorscheme.cpp @@ -27,13 +27,6 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_colorscheme.cpp -/// @ingroup audio_ui -/// -/// Manage colour schemes for the audio display - -#include - #include "audio_colorscheme.h" #include "audio_rendering_style.h" diff --git a/src/audio_controller.cpp b/src/audio_controller.cpp index 709f1067d..487ad39ca 100644 --- a/src/audio_controller.cpp +++ b/src/audio_controller.cpp @@ -35,8 +35,6 @@ #include "include/aegisub/context.h" #include "options.h" #include "project.h" -#include "selection_controller.h" -#include "utils.h" #include diff --git a/src/audio_controller.h b/src/audio_controller.h index 87f3dcdcd..8cef88568 100644 --- a/src/audio_controller.h +++ b/src/audio_controller.h @@ -28,7 +28,6 @@ // Aegisub Project http://www.aegisub.org/ #include -#include #include #include diff --git a/src/audio_display.cpp b/src/audio_display.cpp index 3843e2b9a..ed664c0dc 100644 --- a/src/audio_display.cpp +++ b/src/audio_display.cpp @@ -28,28 +28,20 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_display.cpp -/// @brief Display audio in the main UI -/// @ingroup audio_ui -/// - #include "audio_display.h" #include "ass_time.h" -#include "audio_colorscheme.h" #include "audio_controller.h" #include "audio_renderer.h" #include "audio_renderer_spectrum.h" #include "audio_renderer_waveform.h" #include "audio_timing.h" -#include "block_cache.h" #include "compat.h" #include "include/aegisub/audio_provider.h" #include "include/aegisub/context.h" #include "include/aegisub/hotkey.h" #include "options.h" #include "project.h" -#include "selection_controller.h" #include "utils.h" #include "video_controller.h" @@ -58,7 +50,6 @@ #include #include -#include #include namespace { diff --git a/src/audio_display.h b/src/audio_display.h index 4c17d4be5..e8c78e397 100644 --- a/src/audio_display.h +++ b/src/audio_display.h @@ -27,11 +27,8 @@ // POSSIBILITY OF SUCH DAMAGE. // // Aegisub Project http://www.aegisub.org/ - -/// @file audio_display.h -/// @see audio_display.cpp -/// @ingroup audio_ui -/// +// +#include #include #include @@ -43,14 +40,11 @@ #include #include -#include - namespace agi { struct Context; } class AudioController; class AudioRenderer; class AudioRendererBitmapProvider; -class AudioKaraoke; class AudioProvider; class TimeRange; @@ -58,7 +52,6 @@ class TimeRange; namespace { class AudioDisplayScrollbar; class AudioDisplayTimeline; - class AudioDisplaySelection; } class AudioMarkerInteractionObject; diff --git a/src/audio_karaoke.cpp b/src/audio_karaoke.cpp index 56ec1288a..4f42bc970 100644 --- a/src/audio_karaoke.cpp +++ b/src/audio_karaoke.cpp @@ -40,7 +40,6 @@ #include #include -#include #include #include #include diff --git a/src/audio_marker.h b/src/audio_marker.h index b953b6cd4..383ab87ac 100644 --- a/src/audio_marker.h +++ b/src/audio_marker.h @@ -16,18 +16,18 @@ #pragma once +#include "time_range.h" + #include #include #include - #include class AudioMarkerKeyframe; class Pen; class Project; class VideoController; -class TimeRange; class VideoPositionMarker; class wxPen; @@ -36,8 +36,6 @@ namespace agi { struct Context; } -#include "time_range.h" - /// @class AudioMarker /// @brief A marker on the audio display class AudioMarker { diff --git a/src/audio_provider.cpp b/src/audio_provider.cpp index 1ea0a6516..ffafd41a9 100644 --- a/src/audio_provider.cpp +++ b/src/audio_provider.cpp @@ -27,23 +27,15 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_provider.cpp -/// @brief Baseclass for audio providers -/// @ingroup audio_input -/// - #include "include/aegisub/audio_provider.h" #include "audio_controller.h" #include "factory_manager.h" -#include "frame_main.h" #include "options.h" #include "utils.h" -#include #include #include -#include #include diff --git a/src/audio_provider_dummy.cpp b/src/audio_provider_dummy.cpp index 1a314ee4f..6a1dc9d08 100644 --- a/src/audio_provider_dummy.cpp +++ b/src/audio_provider_dummy.cpp @@ -27,17 +27,12 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_provider_dummy.cpp -/// @brief Dummy (silence or noise) audio provider -/// @ingroup audio_input -/// - #include "include/aegisub/audio_provider.h" -#include #include #include +#include /* * scheme ::= "dummy-audio" ":" signal-specifier "?" signal-parameters diff --git a/src/audio_provider_hd.cpp b/src/audio_provider_hd.cpp index fc166fea2..2ad845b01 100644 --- a/src/audio_provider_hd.cpp +++ b/src/audio_provider_hd.cpp @@ -17,7 +17,6 @@ #include "include/aegisub/audio_provider.h" #include "audio_controller.h" -#include "compat.h" #include "options.h" #include @@ -25,13 +24,10 @@ #include #include -#include -#include -#include +#include #include #include #include -#include namespace { class HDAudioProvider final : public AudioProviderWrapper { diff --git a/src/audio_provider_pcm.cpp b/src/audio_provider_pcm.cpp index 024b73d12..a9fc39674 100644 --- a/src/audio_provider_pcm.cpp +++ b/src/audio_provider_pcm.cpp @@ -27,19 +27,12 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_provider_pcm.cpp -/// @brief PCM WAV and WAV64 audio provider -/// @ingroup audio_input -/// - #include "include/aegisub/audio_provider.h" #include "audio_controller.h" -#include "utils.h" #include #include -#include #include #include diff --git a/src/audio_provider_ram.cpp b/src/audio_provider_ram.cpp index 2f0aa5d1c..b03b4648a 100644 --- a/src/audio_provider_ram.cpp +++ b/src/audio_provider_ram.cpp @@ -35,14 +35,12 @@ #include "include/aegisub/audio_provider.h" #include "audio_controller.h" -#include "compat.h" #include #include #include #include -#include namespace { diff --git a/src/audio_renderer.cpp b/src/audio_renderer.cpp index 5f804672e..90872fce2 100644 --- a/src/audio_renderer.cpp +++ b/src/audio_renderer.cpp @@ -38,10 +38,7 @@ #include #include -#include - -#include -#include +#include namespace { template diff --git a/src/audio_renderer.h b/src/audio_renderer.h index 0ccd928bc..c0f53ee97 100644 --- a/src/audio_renderer.h +++ b/src/audio_renderer.h @@ -27,29 +27,20 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_renderer.h -/// @see audio_renderer.cpp -/// @ingroup audio_ui -/// -/// Base classes for audio renderers (spectrum, waveform, ...) - #pragma once #include #include -#include #include #include "audio_rendering_style.h" #include "block_cache.h" -// Some forward declarations for outside stuff class AudioProvider; - -// Forwards declarations for internal stuff class AudioRendererBitmapProvider; class AudioRenderer; +class wxDC; /// @class AudioRendererBitmapCacheBitmapFactory /// @brief Produces wxBitmap objects for DataBlockCache storage for the audio renderer diff --git a/src/audio_renderer_spectrum.cpp b/src/audio_renderer_spectrum.cpp index bbb60bd05..5aedb4b10 100644 --- a/src/audio_renderer_spectrum.cpp +++ b/src/audio_renderer_spectrum.cpp @@ -39,15 +39,12 @@ #include "fft.h" #endif #include "include/aegisub/audio_provider.h" -#include "utils.h" -#include #include #include #include -#include #include /// Allocates blocks of derived data for the audio spectrum diff --git a/src/audio_renderer_waveform.cpp b/src/audio_renderer_waveform.cpp index f0dab3386..ee9b18df9 100644 --- a/src/audio_renderer_waveform.cpp +++ b/src/audio_renderer_waveform.cpp @@ -27,23 +27,16 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_renderer_waveform.cpp -/// @ingroup audio_ui -/// -/// Render a waveform display of PCM audio data - #include "audio_renderer_waveform.h" +#include "audio_colorscheme.h" +#include "include/aegisub/audio_provider.h" +#include "options.h" + #include #include -#include "audio_colorscheme.h" -#include "block_cache.h" -#include "colorspace.h" -#include "include/aegisub/audio_provider.h" -#include "options.h" - enum { /// Only render the peaks Waveform_MaxOnly = 0, diff --git a/src/audio_renderer_waveform.h b/src/audio_renderer_waveform.h index 79213421b..a07a9a2be 100644 --- a/src/audio_renderer_waveform.h +++ b/src/audio_renderer_waveform.h @@ -27,19 +27,14 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_renderer_waveform.h -/// @see audio_renderer_waveform.cpp -/// @ingroup audio_ui -/// -/// Render a waveform display of PCM audio data +#include "audio_renderer.h" -#include #include class AudioColorScheme; +class wxArrayString; -#include "audio_renderer.h" - +/// Render a waveform display of PCM audio data class AudioWaveformRenderer final : public AudioRendererBitmapProvider { /// Colour tables used for rendering std::vector colors; diff --git a/src/audio_timing_dialogue.cpp b/src/audio_timing_dialogue.cpp index 43a8074a8..6a1bf2197 100644 --- a/src/audio_timing_dialogue.cpp +++ b/src/audio_timing_dialogue.cpp @@ -27,14 +27,11 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_timing_dialogue.cpp -/// @brief Default timing mode for dialogue subtitles -/// @ingroup audio_ui - #include "ass_dialogue.h" #include "ass_file.h" #include "ass_time.h" -#include "audio_renderer.h" +#include "audio_marker.h" +#include "audio_rendering_style.h" #include "audio_timing.h" #include "command/command.h" #include "include/aegisub/context.h" @@ -46,7 +43,6 @@ #include #include -#include #include namespace { diff --git a/src/audio_timing_karaoke.cpp b/src/audio_timing_karaoke.cpp index dd66288e8..b848ef582 100644 --- a/src/audio_timing_karaoke.cpp +++ b/src/audio_timing_karaoke.cpp @@ -14,18 +14,14 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_timing_karaoke.cpp -/// @brief Timing mode for karaoke -/// @ingroup audio_ui -/// - #include #include "ass_dialogue.h" #include "ass_file.h" #include "ass_karaoke.h" #include "audio_controller.h" -#include "audio_renderer.h" +#include "audio_marker.h" +#include "audio_rendering_style.h" #include "audio_timing.h" #include "compat.h" #include "include/aegisub/context.h" @@ -39,6 +35,7 @@ #include #include #include +#include /// @class KaraokeMarker /// @brief AudioMarker implementation for AudioTimingControllerKaraoke diff --git a/src/auto4_base.cpp b/src/auto4_base.cpp index 8f15129fd..f113a544e 100644 --- a/src/auto4_base.cpp +++ b/src/auto4_base.cpp @@ -27,23 +27,16 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file auto4_base.cpp -/// @brief Baseclasses for Automation 4 scripting framework -/// @ingroup scripting -/// - #include "auto4_base.h" #include "ass_file.h" #include "ass_style.h" -#include "command/command.h" +#include "compat.h" #include "dialog_progress.h" #include "include/aegisub/context.h" #include "options.h" #include "string_codec.h" #include "subs_controller.h" -#include "subtitle_format.h" -#include "utils.h" #include #include @@ -59,7 +52,6 @@ #include #include #include -#include #ifdef __WINDOWS__ #define WIN32_LEAN_AND_MEAN @@ -511,4 +503,8 @@ namespace Automation4 { return fnfilter; } + + std::string UnknownScript::GetDescription() const { + return from_wx(_("File was not recognized as a script")); + } } diff --git a/src/auto4_base.h b/src/auto4_base.h index 95a204111..be67d3f7c 100644 --- a/src/auto4_base.h +++ b/src/auto4_base.h @@ -40,14 +40,11 @@ #include #include "ass_export_filter.h" -#include "compat.h" #include #include #include -#include - class AssStyle; class DialogProgress; class wxWindow; @@ -283,7 +280,7 @@ namespace Automation4 { void Reload() override { } std::string GetName() const override { return GetFilename().stem().string(); } - std::string GetDescription() const override { return from_wx(_("File was not recognized as a script")); } + std::string GetDescription() const override; std::string GetAuthor() const override { return ""; } std::string GetVersion() const override { return ""; } bool GetLoadedState() const override { return false; } diff --git a/src/auto4_lua.cpp b/src/auto4_lua.cpp index 943495de1..098168588 100644 --- a/src/auto4_lua.cpp +++ b/src/auto4_lua.cpp @@ -34,18 +34,15 @@ #include "auto4_lua.h" -#include "ass_attachment.h" #include "ass_dialogue.h" -#include "ass_info.h" #include "ass_file.h" +#include "ass_info.h" #include "ass_style.h" #include "async_video_provider.h" #include "auto4_lua_factory.h" #include "command/command.h" #include "compat.h" #include "include/aegisub/context.h" -#include "include/aegisub/video_provider.h" -#include "main.h" #include "options.h" #include "project.h" #include "selection_controller.h" @@ -53,7 +50,6 @@ #include "video_controller.h" #include "utils.h" -#include #include #include #include @@ -67,14 +63,10 @@ #include #include #include -#include #include #include -#include -#include #include #include -#include using namespace agi::lua; using namespace Automation4; diff --git a/src/auto4_lua.h b/src/auto4_lua.h index b647081f1..a3d284558 100644 --- a/src/auto4_lua.h +++ b/src/auto4_lua.h @@ -27,23 +27,16 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file auto4_lua.h -/// @see auto4_lua.cpp -/// @ingroup scripting -/// - #include "auto4_base.h" #include #include - -#include -#include +#include class AssEntry; +class wxControl; class wxWindow; struct lua_State; -namespace agi { namespace vfr { class Framerate; } } namespace Automation4 { /// @class LuaAssFile diff --git a/src/auto4_lua_assfile.cpp b/src/auto4_lua_assfile.cpp index 9bf9a7336..63ad6c475 100644 --- a/src/auto4_lua_assfile.cpp +++ b/src/auto4_lua_assfile.cpp @@ -39,7 +39,7 @@ #include "ass_file.h" #include "ass_karaoke.h" #include "ass_style.h" -#include "utils.h" +#include "compat.h" #include #include diff --git a/src/auto4_lua_dialog.cpp b/src/auto4_lua_dialog.cpp index 6b123e2ac..5dc5cfb76 100644 --- a/src/auto4_lua_dialog.cpp +++ b/src/auto4_lua_dialog.cpp @@ -34,11 +34,9 @@ #include "auto4_lua.h" -#include "ass_style.h" #include "colour_button.h" #include "compat.h" #include "string_codec.h" -#include "utils.h" #include "validators.h" #include @@ -46,24 +44,21 @@ #include #include -#include +#include #include #include -#include #include #include #include #include #include +#include #include #include #include #include -#include #include -#include -#include using namespace agi::lua; namespace { diff --git a/src/auto4_lua_progresssink.cpp b/src/auto4_lua_progresssink.cpp index 80b42087c..bb6b8f1ba 100644 --- a/src/auto4_lua_progresssink.cpp +++ b/src/auto4_lua_progresssink.cpp @@ -34,6 +34,8 @@ #include "auto4_lua.h" +#include "compat.h" + #include #include diff --git a/src/base_grid.cpp b/src/base_grid.cpp index 1a2f6fc24..7d276c989 100644 --- a/src/base_grid.cpp +++ b/src/base_grid.cpp @@ -37,7 +37,6 @@ #include "ass_file.h" #include "audio_box.h" #include "compat.h" -#include "frame_main.h" #include "grid_column.h" #include "options.h" #include "project.h" @@ -49,13 +48,8 @@ #include #include -#include -#include -#include -#include #include -#include #include #include #include @@ -63,10 +57,10 @@ namespace { #ifdef __WXMSW__ class PaintDC : public wxBufferedDC { - wxPaintDC dc; + wxPaintDC dc; public: - PaintDC(wxWindow *window) : dc(window) { + PaintDC(wxWindow *window) : dc(window) { dc.SetLayoutDirection(wxLayout_LeftToRight); Init(&dc, window->GetClientSize(), 0); if (window->GetLayoutDirection() == wxLayout_RightToLeft) { @@ -75,7 +69,7 @@ public: } } - ~PaintDC() { + ~PaintDC() { SetLayoutDirection(wxLayout_LeftToRight); SetLogicalOrigin(0, 0); UnMask(); diff --git a/src/base_grid.h b/src/base_grid.h index 8967d519a..2163ba9e9 100644 --- a/src/base_grid.h +++ b/src/base_grid.h @@ -29,7 +29,6 @@ #include -#include #include #include #include diff --git a/src/colour_button.cpp b/src/colour_button.cpp index 1e37d81c7..f985e62f1 100644 --- a/src/colour_button.cpp +++ b/src/colour_button.cpp @@ -16,7 +16,6 @@ #include "colour_button.h" -#include "compat.h" #include "dialogs.h" #include diff --git a/src/command/audio.cpp b/src/command/audio.cpp index 45ee75eac..66db86e66 100644 --- a/src/command/audio.cpp +++ b/src/command/audio.cpp @@ -36,7 +36,6 @@ #include "../audio_controller.h" #include "../audio_karaoke.h" #include "../audio_timing.h" -#include "../compat.h" #include "../include/aegisub/audio_provider.h" #include "../include/aegisub/context.h" #include "../libresrc/libresrc.h" @@ -47,11 +46,8 @@ #include "../video_controller.h" #include -#include #include -#include - namespace { using cmd::Command; diff --git a/src/command/automation.cpp b/src/command/automation.cpp index fb8fe282e..817bfabb5 100644 --- a/src/command/automation.cpp +++ b/src/command/automation.cpp @@ -37,9 +37,6 @@ #include "../include/aegisub/context.h" #include "../libresrc/libresrc.h" #include "../main.h" -#include "../options.h" -#include "../utils.h" -#include "../video_controller.h" #include diff --git a/src/command/command.h b/src/command/command.h index a22e97a60..e3ea33f54 100644 --- a/src/command/command.h +++ b/src/command/command.h @@ -16,7 +16,6 @@ /// @brief Command base class and main header. /// @ingroup command - #include #include #include diff --git a/src/command/edit.cpp b/src/command/edit.cpp index a78fe090d..288a2dfd7 100644 --- a/src/command/edit.cpp +++ b/src/command/edit.cpp @@ -43,10 +43,8 @@ #include "../libresrc/libresrc.h" #include "../options.h" #include "../project.h" -#include "../search_replace_engine.h" #include "../selection_controller.h" #include "../subs_controller.h" -#include "../subs_edit_ctrl.h" #include "../text_selection_controller.h" #include "../utils.h" #include "../video_controller.h" @@ -64,10 +62,12 @@ #include #include #include +#include #include #include #include +#include namespace { using namespace boost::adaptors; diff --git a/src/command/grid.cpp b/src/command/grid.cpp index e69ef4b5c..d0a9d165b 100644 --- a/src/command/grid.cpp +++ b/src/command/grid.cpp @@ -40,7 +40,6 @@ #include "../libresrc/libresrc.h" #include "../options.h" #include "../selection_controller.h" -#include "../utils.h" #include diff --git a/src/command/help.cpp b/src/command/help.cpp index cfdb345fd..144a1f81a 100644 --- a/src/command/help.cpp +++ b/src/command/help.cpp @@ -34,7 +34,6 @@ #include "../help_button.h" #include "../include/aegisub/context.h" #include "../libresrc/libresrc.h" -#include "../options.h" #include diff --git a/src/command/recent.cpp b/src/command/recent.cpp index 21e954d8a..4e2a980f4 100644 --- a/src/command/recent.cpp +++ b/src/command/recent.cpp @@ -29,7 +29,6 @@ #include "command.h" -#include "../compat.h" #include "../include/aegisub/context.h" #include "../libresrc/libresrc.h" #include "../options.h" diff --git a/src/command/subtitle.cpp b/src/command/subtitle.cpp index c95590690..24175191c 100644 --- a/src/command/subtitle.cpp +++ b/src/command/subtitle.cpp @@ -51,7 +51,7 @@ #include #include -#include +#include #include #include diff --git a/src/command/time.cpp b/src/command/time.cpp index da21265b0..3e7a8f66b 100644 --- a/src/command/time.cpp +++ b/src/command/time.cpp @@ -39,7 +39,6 @@ #include "../dialogs.h" #include "../include/aegisub/context.h" #include "../libresrc/libresrc.h" -#include "../options.h" #include "../project.h" #include "../selection_controller.h" #include "../video_controller.h" diff --git a/src/command/video.cpp b/src/command/video.cpp index f4823ab57..49e4b2be0 100644 --- a/src/command/video.cpp +++ b/src/command/video.cpp @@ -46,11 +46,9 @@ #include "../project.h" #include "../selection_controller.h" #include "../utils.h" -#include "../video_box.h" #include "../video_controller.h" #include "../video_display.h" #include "../video_frame.h" -#include "../video_slider.h" #include #include @@ -61,7 +59,6 @@ #include #include #include -#include #include #include diff --git a/src/command/vis_tool.cpp b/src/command/vis_tool.cpp index 0cfd308b1..168f427ee 100644 --- a/src/command/vis_tool.cpp +++ b/src/command/vis_tool.cpp @@ -19,8 +19,6 @@ #include "../include/aegisub/context.h" #include "../libresrc/libresrc.h" #include "../project.h" -#include "../video_box.h" -#include "../video_controller.h" #include "../video_display.h" #include "../visual_tool_clip.h" #include "../visual_tool_cross.h" diff --git a/src/dialog_automation.cpp b/src/dialog_automation.cpp index 52a877954..69ef63033 100644 --- a/src/dialog_automation.cpp +++ b/src/dialog_automation.cpp @@ -36,12 +36,11 @@ #include "libresrc/libresrc.h" #include "options.h" #include "main.h" -#include "subtitle_format.h" #include #include -#include +#include #include #include diff --git a/src/dialog_autosave.cpp b/src/dialog_autosave.cpp index 5c015aebb..00c7ada9c 100644 --- a/src/dialog_autosave.cpp +++ b/src/dialog_autosave.cpp @@ -20,7 +20,6 @@ #include -#include #include #include #include @@ -31,7 +30,6 @@ #include #include #include -#include #include namespace { diff --git a/src/dialog_colorpicker.cpp b/src/dialog_colorpicker.cpp index e5e7f2354..6e03df8ed 100644 --- a/src/dialog_colorpicker.cpp +++ b/src/dialog_colorpicker.cpp @@ -27,7 +27,6 @@ // // Aegisub Project http://www.aegisub.org/ -#include "ass_style.h" #include "colorspace.h" #include "compat.h" #include "help_button.h" @@ -50,7 +49,6 @@ #include #include #include -#include #include #include #include diff --git a/src/dialog_dummy_video.cpp b/src/dialog_dummy_video.cpp index be56aad0d..85e5aed89 100644 --- a/src/dialog_dummy_video.cpp +++ b/src/dialog_dummy_video.cpp @@ -34,7 +34,6 @@ #include #include #include -#include namespace { struct DialogDummyVideo final : wxDialog { diff --git a/src/dialog_export.cpp b/src/dialog_export.cpp index 347ba863e..a6e5d455f 100644 --- a/src/dialog_export.cpp +++ b/src/dialog_export.cpp @@ -37,7 +37,6 @@ #include "utils.h" #include -#include #include #include diff --git a/src/dialog_export_ebu3264.cpp b/src/dialog_export_ebu3264.cpp index aa2d47160..f2eb54c78 100644 --- a/src/dialog_export_ebu3264.cpp +++ b/src/dialog_export_ebu3264.cpp @@ -23,7 +23,6 @@ #include "compat.h" #include "options.h" -#include "text_file_writer.h" #include #include diff --git a/src/dialog_fonts_collector.cpp b/src/dialog_fonts_collector.cpp index 059046bbf..c82e763e8 100644 --- a/src/dialog_fonts_collector.cpp +++ b/src/dialog_fonts_collector.cpp @@ -17,7 +17,6 @@ #include "font_file_lister.h" #include "font_file_lister_fontconfig.h" -#include "ass_file.h" #include "compat.h" #include "dialog_manager.h" #include "help_button.h" @@ -25,8 +24,6 @@ #include "libresrc/libresrc.h" #include "options.h" #include "scintilla_text_ctrl.h" -#include "selection_controller.h" -#include "subs_controller.h" #include "utils.h" #include diff --git a/src/dialog_jumpto.cpp b/src/dialog_jumpto.cpp index 6356483f0..1c5fce2b8 100644 --- a/src/dialog_jumpto.cpp +++ b/src/dialog_jumpto.cpp @@ -36,7 +36,6 @@ #include "validators.h" #include "video_controller.h" -#include #include #include #include diff --git a/src/dialog_kara_timing_copy.cpp b/src/dialog_kara_timing_copy.cpp index 0940e8a06..7b0db5184 100644 --- a/src/dialog_kara_timing_copy.cpp +++ b/src/dialog_kara_timing_copy.cpp @@ -36,17 +36,11 @@ #include "include/aegisub/context.h" #include "libresrc/libresrc.h" #include "options.h" -#include "selection_controller.h" -#include "utils.h" #include -#include -#include #include -#include #include -#include #include #include #include diff --git a/src/dialog_log.cpp b/src/dialog_log.cpp index 02e3962ef..b66e10569 100644 --- a/src/dialog_log.cpp +++ b/src/dialog_log.cpp @@ -34,10 +34,7 @@ #include #include -#include #include -#include -#include #include #include #include diff --git a/src/dialog_properties.cpp b/src/dialog_properties.cpp index d209fb8dc..eae2f49e8 100644 --- a/src/dialog_properties.cpp +++ b/src/dialog_properties.cpp @@ -37,7 +37,6 @@ #include "resolution_resampler.h" #include "validators.h" -#include #include #include #include diff --git a/src/dialog_selection.cpp b/src/dialog_selection.cpp index 0dd29518f..260ddde84 100644 --- a/src/dialog_selection.cpp +++ b/src/dialog_selection.cpp @@ -25,11 +25,8 @@ #include "options.h" #include "search_replace_engine.h" #include "selection_controller.h" -#include "utils.h" -#include -#include -#include +#include #include #include @@ -255,4 +252,4 @@ void DialogSelection::OnDialogueCheckbox(wxCheckBox *chk) { void ShowSelectLinesDialog(agi::Context *c) { c->dialog->Show(c); -} \ No newline at end of file +} diff --git a/src/dialog_shift_times.cpp b/src/dialog_shift_times.cpp index a36b3e5b3..656c1d61d 100644 --- a/src/dialog_shift_times.cpp +++ b/src/dialog_shift_times.cpp @@ -39,9 +39,7 @@ #include #include -#include #include -#include #include #include #include diff --git a/src/dialog_spellchecker.cpp b/src/dialog_spellchecker.cpp index 99314fbea..88e0595e6 100644 --- a/src/dialog_spellchecker.cpp +++ b/src/dialog_spellchecker.cpp @@ -25,8 +25,6 @@ #include "options.h" #include "selection_controller.h" #include "text_selection_controller.h" -#include "subs_edit_ctrl.h" -#include "utils.h" #include #include diff --git a/src/dialog_style_editor.cpp b/src/dialog_style_editor.cpp index fc80ef604..a1b947b11 100644 --- a/src/dialog_style_editor.cpp +++ b/src/dialog_style_editor.cpp @@ -55,8 +55,10 @@ #include #include +#include #include #include +#include #include /// Style rename helper that walks a file searching for a style and optionally diff --git a/src/dialog_style_editor.h b/src/dialog_style_editor.h index 6fa0033fd..f505daa67 100644 --- a/src/dialog_style_editor.h +++ b/src/dialog_style_editor.h @@ -27,25 +27,25 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file dialog_style_editor.h -/// @see dialog_style_editor.cpp -/// @ingroup style_editor -/// - #include - -#include -#include +#include #include -#include -#include -#include -namespace agi { struct Context; } class AssStyle; class AssStyleStorage; class PersistLocation; class SubtitlesPreview; +class wxArrayString; +class wxCheckBox; +class wxChildFocusEvent; +class wxComboBox; +class wxCommandEvent; +class wxRadioBox; +class wxSpinCtrl; +class wxTextCtrl; +class wxThreadEvent; +class wxWindow; +namespace agi { struct Context; } class DialogStyleEditor final : public wxDialog { agi::Context *c; diff --git a/src/dialog_style_manager.cpp b/src/dialog_style_manager.cpp index 4fceb00e7..eeaa72805 100644 --- a/src/dialog_style_manager.cpp +++ b/src/dialog_style_manager.cpp @@ -42,9 +42,7 @@ #include "options.h" #include "persist_location.h" #include "selection_controller.h" -#include "subs_controller.h" #include "subtitle_format.h" -#include "utils.h" #include #include @@ -60,14 +58,18 @@ #include #include #include +#include +#include #include -#include #include #include #include #include #include +#include #include +#include +#include #include #include // Keep this last so wxUSE_CHOICEDLG is set. @@ -334,43 +336,43 @@ DialogStyleManager::DialogStyleManager(agi::Context *context) StorageList->Bind(wxEVT_KEY_DOWN, &DialogStyleManager::OnKeyDown, this); CurrentList->Bind(wxEVT_KEY_DOWN, &DialogStyleManager::OnKeyDown, this); - StorageMoveUp->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, true, 0)); - StorageMoveTop->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, true, 1)); - StorageMoveDown->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, true, 2)); - StorageMoveBottom->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, true, 3)); - StorageSort->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, true, 4)); + StorageMoveUp->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(true, 0); }); + StorageMoveTop->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(true, 1); }); + StorageMoveDown->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(true, 2); }); + StorageMoveBottom->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(true, 3); }); + StorageSort->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(true, 4); }); - CurrentMoveUp->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, false, 0)); - CurrentMoveTop->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, false, 1)); - CurrentMoveDown->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, false, 2)); - CurrentMoveBottom->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, false, 3)); - CurrentSort->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::MoveStyles, this, false, 4)); + CurrentMoveUp->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(false, 0); }); + CurrentMoveTop->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(false, 1); }); + CurrentMoveDown->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(false, 2); }); + CurrentMoveBottom->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(false, 3); }); + CurrentSort->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { MoveStyles(false, 4); }); - CatalogNew->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCatalogNew, this)); - CatalogDelete->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCatalogDelete, this)); + CatalogNew->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCatalogNew(); }); + CatalogDelete->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCatalogDelete(); }); - StorageNew->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnStorageNew, this)); - StorageEdit->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnStorageEdit, this)); - StorageCopy->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnStorageCopy, this)); - StorageDelete->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnStorageDelete, this)); + StorageNew->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnStorageNew(); }); + StorageEdit->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnStorageEdit(); }); + StorageCopy->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnStorageCopy(); }); + StorageDelete->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnStorageDelete(); }); - CurrentNew->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCurrentNew, this)); - CurrentEdit->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCurrentEdit, this)); - CurrentCopy->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCurrentCopy, this)); - CurrentDelete->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCurrentDelete, this)); + CurrentNew->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCurrentNew(); }); + CurrentEdit->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCurrentEdit(); }); + CurrentCopy->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCurrentCopy(); }); + CurrentDelete->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCurrentDelete(); }); - CurrentImport->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCurrentImport, this)); + CurrentImport->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCurrentImport(); }); - MoveToLocal->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCopyToCurrent, this)); - MoveToStorage->Bind(wxEVT_BUTTON, bind(&DialogStyleManager::OnCopyToStorage, this)); + MoveToLocal->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCopyToCurrent(); }); + MoveToStorage->Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OnCopyToStorage(); }); - CatalogList->Bind(wxEVT_COMBOBOX, bind(&DialogStyleManager::OnChangeCatalog, this)); + CatalogList->Bind(wxEVT_COMBOBOX, [=](wxCommandEvent&) { OnChangeCatalog(); }); - StorageList->Bind(wxEVT_LISTBOX, bind(&DialogStyleManager::UpdateButtons, this)); - StorageList->Bind(wxEVT_LISTBOX_DCLICK, bind(&DialogStyleManager::OnStorageEdit, this)); + StorageList->Bind(wxEVT_LISTBOX, [=](wxCommandEvent&) { UpdateButtons(); }); + StorageList->Bind(wxEVT_LISTBOX_DCLICK, [=](wxCommandEvent&) { OnStorageEdit(); }); - CurrentList->Bind(wxEVT_LISTBOX, bind(&DialogStyleManager::UpdateButtons, this)); - CurrentList->Bind(wxEVT_LISTBOX_DCLICK, bind(&DialogStyleManager::OnCurrentEdit, this)); + CurrentList->Bind(wxEVT_LISTBOX, [=](wxCommandEvent&) { UpdateButtons(); }); + CurrentList->Bind(wxEVT_LISTBOX_DCLICK, [=](wxCommandEvent&) { OnCurrentEdit(); }); } void DialogStyleManager::LoadCurrentStyles(int commit_type) { diff --git a/src/dialog_styling_assistant.cpp b/src/dialog_styling_assistant.cpp index d8e7c8b2a..77688cad9 100644 --- a/src/dialog_styling_assistant.cpp +++ b/src/dialog_styling_assistant.cpp @@ -26,8 +26,6 @@ #include "ass_dialogue.h" #include "ass_file.h" -#include "ass_style.h" -#include "audio_controller.h" #include "command/command.h" #include "compat.h" #include "help_button.h" @@ -41,6 +39,7 @@ #include #include +#include #include #include #include diff --git a/src/dialog_styling_assistant.h b/src/dialog_styling_assistant.h index 33c09229b..1658bcf77 100644 --- a/src/dialog_styling_assistant.h +++ b/src/dialog_styling_assistant.h @@ -18,15 +18,17 @@ #include #include -#include -namespace agi { struct Context; } class AssDialogue; class PersistLocation; +class wxActivateEvent; class wxButton; class wxCheckBox; +class wxCommandEvent; +class wxKeyEvent; class wxListBox; class wxTextCtrl; +namespace agi { struct Context; } class DialogStyling final : public wxDialog { agi::Context *c; diff --git a/src/dialog_timing_processor.cpp b/src/dialog_timing_processor.cpp index af4cb8d9d..39860d5c0 100644 --- a/src/dialog_timing_processor.cpp +++ b/src/dialog_timing_processor.cpp @@ -45,7 +45,7 @@ #include #include #include -#include +#include #include #include #include @@ -447,4 +447,4 @@ void DialogTimingProcessor::Process() { void ShowTimingProcessorDialog(agi::Context *c) { DialogTimingProcessor(c).ShowModal(); -} \ No newline at end of file +} diff --git a/src/dialog_translation.cpp b/src/dialog_translation.cpp index 755d4436a..a78a6ebc4 100644 --- a/src/dialog_translation.cpp +++ b/src/dialog_translation.cpp @@ -26,7 +26,6 @@ #include "ass_dialogue.h" #include "ass_file.h" -#include "audio_controller.h" #include "command/command.h" #include "compat.h" #include "help_button.h" @@ -35,7 +34,6 @@ #include "project.h" #include "subs_edit_ctrl.h" #include "selection_controller.h" -#include "utils.h" #include "video_controller.h" #include diff --git a/src/dialog_version_check.cpp b/src/dialog_version_check.cpp index 6c48f1cc3..3339d4d37 100644 --- a/src/dialog_version_check.cpp +++ b/src/dialog_version_check.cpp @@ -43,16 +43,13 @@ #include #include -#include #include #include #include #include #include #include -#include #include -#include #include #include #include diff --git a/src/export_framerate.cpp b/src/export_framerate.cpp index fc9c8c484..d27b9e4e7 100644 --- a/src/export_framerate.cpp +++ b/src/export_framerate.cpp @@ -35,7 +35,6 @@ #include "compat.h" #include "include/aegisub/context.h" #include "project.h" -#include "utils.h" #include diff --git a/src/ffmpegsource_common.cpp b/src/ffmpegsource_common.cpp index 05e0b78e2..9c806dd94 100644 --- a/src/ffmpegsource_common.cpp +++ b/src/ffmpegsource_common.cpp @@ -36,21 +36,18 @@ #include "ffmpegsource_common.h" #include "compat.h" -#include "frame_main.h" #include "options.h" #include "utils.h" #include #include #include -#include #include #include -#include -#include - -#include // Keep this last so wxUSE_CHOICEDLG is set. +#include +#include +#include #ifdef _WIN32 #include diff --git a/src/font_file_lister.cpp b/src/font_file_lister.cpp index a049d5c9c..0a40a68d0 100644 --- a/src/font_file_lister.cpp +++ b/src/font_file_lister.cpp @@ -25,7 +25,6 @@ #include "ass_file.h" #include "ass_style.h" #include "compat.h" -#include "utils.h" #include #include diff --git a/src/font_file_lister_fontconfig.cpp b/src/font_file_lister_fontconfig.cpp index bc9d29804..94924ad1b 100644 --- a/src/font_file_lister_fontconfig.cpp +++ b/src/font_file_lister_fontconfig.cpp @@ -22,7 +22,6 @@ #include "font_file_lister_fontconfig.h" #include -#include #ifdef __APPLE__ #include diff --git a/src/frame_main.cpp b/src/frame_main.cpp index 24b55aa37..466f95651 100644 --- a/src/frame_main.cpp +++ b/src/frame_main.cpp @@ -47,33 +47,24 @@ #include "command/command.h" #include "dialog_detached_video.h" #include "dialog_manager.h" -#include "help_button.h" #include "libresrc/libresrc.h" #include "main.h" #include "options.h" #include "project.h" #include "subs_controller.h" #include "subs_edit_box.h" -#include "subs_edit_ctrl.h" #include "utils.h" #include "version.h" #include "video_box.h" #include "video_controller.h" #include "video_display.h" -#include "video_slider.h" -#include #include #include -#include -#include - -#include #include -#include -#include #include +#include #include #include diff --git a/src/frame_main.h b/src/frame_main.h index 985b131ce..b91d3b2a6 100644 --- a/src/frame_main.h +++ b/src/frame_main.h @@ -27,12 +27,8 @@ // // Aegisub Project http://www.aegisub.org/ -#include - #include -#include #include -#include #include class AegisubApp; @@ -77,9 +73,9 @@ class FrameMain : public wxFrame { AudioBox *audioBox; ///< The audio area VideoBox *videoBox; ///< The video area - wxBoxSizer *MainSizer; ///< Arranges things from top to bottom in the window - wxBoxSizer *TopSizer; ///< Arranges video box and tool box from left to right - wxBoxSizer *ToolsSizer; ///< Arranges audio and editing areas top to bottom + wxSizer *MainSizer; ///< Arranges things from top to bottom in the window + wxSizer *TopSizer; ///< Arranges video box and tool box from left to right + wxSizer *ToolsSizer; ///< Arranges audio and editing areas top to bottom public: FrameMain(); diff --git a/src/gl_text.h b/src/gl_text.h index aeb888bef..e25045f12 100644 --- a/src/gl_text.h +++ b/src/gl_text.h @@ -27,14 +27,8 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file gl_text.h -/// @see gl_text.cpp -/// @ingroup video_output -/// - #include -#include #include #include diff --git a/src/help_button.cpp b/src/help_button.cpp index 043f4c7fa..5a3c00658 100644 --- a/src/help_button.cpp +++ b/src/help_button.cpp @@ -27,23 +27,11 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file help_button.cpp -/// @brief Push-button opening the help file at a specified section -/// @ingroup custom_control -/// - #include "help_button.h" -#include "options.h" - #include -#include #include -#include -#include - -#include namespace { static boost::container::flat_map pages; @@ -78,7 +66,7 @@ void init_static() { HelpButton::HelpButton(wxWindow *parent, wxString const& page, wxPoint position, wxSize size) : wxButton(parent, wxID_HELP, "", position, size) { - Bind(wxEVT_BUTTON, std::bind(&HelpButton::OpenPage, page)); + Bind(wxEVT_BUTTON, [=](wxCommandEvent&) { OpenPage(page); }); init_static(); if (pages.find(page) == pages.end()) throw agi::InternalError("Invalid help page", nullptr); diff --git a/src/help_button.h b/src/help_button.h index 143e45c3b..885f81099 100644 --- a/src/help_button.h +++ b/src/help_button.h @@ -27,11 +27,6 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file help_button.h -/// @see help_button.cpp -/// @ingroup custom_control -/// - #include class HelpButton final : public wxButton { diff --git a/src/include/aegisub/audio_provider.h b/src/include/aegisub/audio_provider.h index 6a35976de..f16c5cf54 100644 --- a/src/include/aegisub/audio_provider.h +++ b/src/include/aegisub/audio_provider.h @@ -27,18 +27,13 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file audio_provider.h -/// @brief Declaration of base-class for audio providers -/// @ingroup main_headers audio_input -/// - #pragma once #include #include #include -#include +#include class AudioProvider { protected: diff --git a/src/main.cpp b/src/main.cpp index b3395e1b0..4ee7b3ede 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -37,7 +37,6 @@ #include "command/command.h" #include "include/aegisub/hotkey.h" -#include "ass_file.h" #include "auto4_base.h" #include "auto4_lua_factory.h" #include "compat.h" @@ -51,14 +50,12 @@ #include "options.h" #include "project.h" #include "subs_controller.h" -#include "subtitle_format.h" #include "subtitles_provider_libass.h" #include "utils.h" #include "version.h" #include #include -#include #include #include #include diff --git a/src/menu.cpp b/src/menu.cpp index c7f938aea..133c48b89 100644 --- a/src/menu.cpp +++ b/src/menu.cpp @@ -28,6 +28,7 @@ #include "main.h" #include "options.h" +#include #include #include #include diff --git a/src/mkv_wrap.cpp b/src/mkv_wrap.cpp index 4bab6d9b1..1fa1cfab7 100644 --- a/src/mkv_wrap.cpp +++ b/src/mkv_wrap.cpp @@ -42,11 +42,9 @@ #include "MatroskaParser.h" #include -#include #include #include -#include #include #include #include diff --git a/src/preferences.cpp b/src/preferences.cpp index 0f2fab6cb..ac3808451 100644 --- a/src/preferences.cpp +++ b/src/preferences.cpp @@ -20,7 +20,6 @@ #include "ass_style_storage.h" #include "audio_renderer_waveform.h" -#include "colour_button.h" #include "command/command.h" #include "compat.h" #include "help_button.h" @@ -42,18 +41,13 @@ #include #endif -#include -#include #include -#include -#include #include #include #include #include -#include #include #include #include @@ -62,9 +56,8 @@ #include #include -#define CLASS_PAGE(name) \ -class name: public OptionPage { \ -public: \ +#define CLASS_PAGE(name) \ +struct name : OptionPage { \ name(wxTreebook *book, Preferences *parent); \ }; diff --git a/src/preferences_base.cpp b/src/preferences_base.cpp index 1e6051e98..25e66fab4 100644 --- a/src/preferences_base.cpp +++ b/src/preferences_base.cpp @@ -20,12 +20,8 @@ #include "colour_button.h" #include "compat.h" -#include "include/aegisub/audio_player.h" -#include "include/aegisub/audio_provider.h" -#include "libresrc/libresrc.h" #include "options.h" #include "preferences.h" -#include "video_provider_manager.h" #include #include @@ -34,7 +30,6 @@ #include #include #include -#include #include #include #include @@ -52,7 +47,7 @@ type(std::string const& n, Preferences *p) : name(n), parent(p) { } \ void operator()(evttype& evt) { \ evt.Skip(); \ - parent->SetOption(agi::make_unique(name, body));\ + parent->SetOption(agi::make_unique(name, body)); \ } \ } diff --git a/src/project.cpp b/src/project.cpp index 82366b2b8..9cd1e3786 100644 --- a/src/project.cpp +++ b/src/project.cpp @@ -37,10 +37,8 @@ #include #include #include -#include #include -#include #include #include diff --git a/src/resolution_resampler.cpp b/src/resolution_resampler.cpp index e6a71ed84..3f116f748 100644 --- a/src/resolution_resampler.cpp +++ b/src/resolution_resampler.cpp @@ -28,9 +28,8 @@ #include #include -#include #include -#include +#include enum { LEFT = 0, diff --git a/src/scintilla_text_ctrl.h b/src/scintilla_text_ctrl.h index 220b1496b..e8ed68f29 100644 --- a/src/scintilla_text_ctrl.h +++ b/src/scintilla_text_ctrl.h @@ -27,15 +27,8 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file scintilla_text_ctrl.h -/// @see scintilla_text_ctrl.cpp -/// @ingroup custom_control -/// - #include -#include - class ScintillaTextCtrl : public wxStyledTextCtrl { wxString text; diff --git a/src/search_replace_engine.cpp b/src/search_replace_engine.cpp index 7e3e4bbdf..92595a551 100644 --- a/src/search_replace_engine.cpp +++ b/src/search_replace_engine.cpp @@ -24,7 +24,7 @@ #include -#include +#include #include diff --git a/src/spline.cpp b/src/spline.cpp index 851eaa03d..1853b1936 100644 --- a/src/spline.cpp +++ b/src/spline.cpp @@ -34,7 +34,6 @@ #include "spline.h" -#include "utils.h" #include "visual_tool.h" #include diff --git a/src/spline_curve.cpp b/src/spline_curve.cpp index 1cc546af5..3de65859b 100644 --- a/src/spline_curve.cpp +++ b/src/spline_curve.cpp @@ -36,7 +36,6 @@ #include "utils.h" #include -#include SplineCurve::SplineCurve(Vector2D p1) : p1(std::move(p1)), type(POINT) { } SplineCurve::SplineCurve(Vector2D p1, Vector2D p2) : p1(std::move(p1)), p2(std::move(p2)), type(LINE) { } diff --git a/src/subs_controller.cpp b/src/subs_controller.cpp index cf446fe0e..1491bde06 100644 --- a/src/subs_controller.cpp +++ b/src/subs_controller.cpp @@ -21,7 +21,6 @@ #include "ass_file.h" #include "ass_info.h" #include "ass_style.h" -#include "ass_style_storage.h" #include "compat.h" #include "command/command.h" #include "frame_main.h" @@ -31,13 +30,11 @@ #include "selection_controller.h" #include "subtitle_format.h" #include "text_selection_controller.h" -#include "utils.h" #include #include #include -#include #include #include diff --git a/src/subs_controller.h b/src/subs_controller.h index 5425e0871..f75af0b93 100644 --- a/src/subs_controller.h +++ b/src/subs_controller.h @@ -19,11 +19,8 @@ #include #include -#include #include -class AssDialogue; -class AssFile; struct AssFileCommit; class SelectionController; diff --git a/src/subs_edit_box.cpp b/src/subs_edit_box.cpp index ff4ab9789..ae34b93e7 100644 --- a/src/subs_edit_box.cpp +++ b/src/subs_edit_box.cpp @@ -43,7 +43,6 @@ #include "include/aegisub/context.h" #include "include/aegisub/hotkey.h" #include "initial_line_state.h" -#include "libresrc/libresrc.h" #include "options.h" #include "project.h" #include "placeholder_ctrl.h" diff --git a/src/subs_edit_box.h b/src/subs_edit_box.h index e8638f524..71e92cdd4 100644 --- a/src/subs_edit_box.h +++ b/src/subs_edit_box.h @@ -27,15 +27,9 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file subs_edit_box.h -/// @see subs_edit_box.cpp -/// @ingroup main_ui -/// - #include #include #include -#include #include #include diff --git a/src/subs_edit_ctrl.cpp b/src/subs_edit_ctrl.cpp index 1d1944fd8..13b5212a1 100644 --- a/src/subs_edit_ctrl.cpp +++ b/src/subs_edit_ctrl.cpp @@ -35,7 +35,6 @@ #include "subs_edit_ctrl.h" #include "ass_dialogue.h" -#include "ass_file.h" #include "command/command.h" #include "compat.h" #include "options.h" diff --git a/src/subs_edit_ctrl.h b/src/subs_edit_ctrl.h index d708f8bb9..6574501c6 100644 --- a/src/subs_edit_ctrl.h +++ b/src/subs_edit_ctrl.h @@ -27,18 +27,12 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file subs_edit_ctrl.h -/// @see subs_edit_ctrl.cpp -/// @ingroup main_ui -/// +#include "scintilla_text_ctrl.h" #include #include #include -#include "scintilla_text_ctrl.h" - -class SubsEditBox; class Thesaurus; namespace agi { class CalltipProvider; diff --git a/src/subtitle_format.cpp b/src/subtitle_format.cpp index 150d2ce2a..2b5741a76 100644 --- a/src/subtitle_format.cpp +++ b/src/subtitle_format.cpp @@ -37,10 +37,8 @@ #include #include // Keep this last so wxUSE_CHOICEDLG is set. -#include "ass_attachment.h" #include "ass_dialogue.h" #include "ass_file.h" -#include "ass_style.h" #include "compat.h" #include "subtitle_format_ass.h" #include "subtitle_format_ebu3264.h" @@ -51,14 +49,12 @@ #include "subtitle_format_transtation.h" #include "subtitle_format_ttxt.h" #include "subtitle_format_txt.h" -#include "video_controller.h" #include #include #include #include -#include #include namespace { diff --git a/src/subtitle_format_encore.cpp b/src/subtitle_format_encore.cpp index 040d5d2a7..59d23be27 100644 --- a/src/subtitle_format_encore.cpp +++ b/src/subtitle_format_encore.cpp @@ -38,8 +38,6 @@ #include "ass_file.h" #include "text_file_writer.h" -#include -#include #include EncoreSubtitleFormat::EncoreSubtitleFormat() @@ -48,9 +46,7 @@ EncoreSubtitleFormat::EncoreSubtitleFormat() } std::vector EncoreSubtitleFormat::GetWriteWildcards() const { - std::vector formats; - formats.push_back("encore.txt"); - return formats; + return {"encore.txt"}; } void EncoreSubtitleFormat::WriteFile(const AssFile *src, agi::fs::path const& filename, agi::vfr::Framerate const& video_fps, std::string const&) const { diff --git a/src/subtitle_format_microdvd.cpp b/src/subtitle_format_microdvd.cpp index bb60e1b9b..af8f4bcf6 100644 --- a/src/subtitle_format_microdvd.cpp +++ b/src/subtitle_format_microdvd.cpp @@ -40,7 +40,6 @@ #include "options.h" #include "text_file_reader.h" #include "text_file_writer.h" -#include "video_controller.h" #include #include @@ -56,9 +55,7 @@ MicroDVDSubtitleFormat::MicroDVDSubtitleFormat() } std::vector MicroDVDSubtitleFormat::GetReadWildcards() const { - std::vector formats; - formats.push_back("sub"); - return formats; + return {"sub"}; } std::vector MicroDVDSubtitleFormat::GetWriteWildcards() const { diff --git a/src/subtitle_format_srt.cpp b/src/subtitle_format_srt.cpp index f08c397ca..ac89d0744 100644 --- a/src/subtitle_format_srt.cpp +++ b/src/subtitle_format_srt.cpp @@ -37,14 +37,11 @@ #include "ass_attachment.h" #include "ass_dialogue.h" #include "ass_file.h" -#include "ass_style.h" #include "options.h" -#include "utils.h" #include "text_file_reader.h" #include "text_file_writer.h" #include -#include #include #include diff --git a/src/subtitle_format_ssa.cpp b/src/subtitle_format_ssa.cpp index 1cd790377..e7a2b3570 100644 --- a/src/subtitle_format_ssa.cpp +++ b/src/subtitle_format_ssa.cpp @@ -24,8 +24,6 @@ #include "text_file_writer.h" #include "version.h" -#include - #include #include #include diff --git a/src/subtitle_format_transtation.cpp b/src/subtitle_format_transtation.cpp index e0646c094..d1a68216c 100644 --- a/src/subtitle_format_transtation.cpp +++ b/src/subtitle_format_transtation.cpp @@ -32,8 +32,6 @@ /// @ingroup subtitle_io /// -#include - #include "subtitle_format_transtation.h" #include "ass_dialogue.h" @@ -42,8 +40,6 @@ #include "ass_time.h" #include "text_file_writer.h" -#include -#include #include TranStationSubtitleFormat::TranStationSubtitleFormat() @@ -52,9 +48,7 @@ TranStationSubtitleFormat::TranStationSubtitleFormat() } std::vector TranStationSubtitleFormat::GetWriteWildcards() const { - std::vector formats; - formats.push_back("transtation.txt"); - return formats; + return {"transtation.txt"}; } void TranStationSubtitleFormat::WriteFile(const AssFile *src, agi::fs::path const& filename, agi::vfr::Framerate const& vfps, std::string const& encoding) const { diff --git a/src/subtitle_format_ttxt.cpp b/src/subtitle_format_ttxt.cpp index 7bd5f3c35..6d2856074 100644 --- a/src/subtitle_format_ttxt.cpp +++ b/src/subtitle_format_ttxt.cpp @@ -34,17 +34,14 @@ #include "subtitle_format_ttxt.h" -#include - #include "ass_dialogue.h" #include "ass_file.h" #include "ass_time.h" #include "compat.h" #include "options.h" -#include - #include +#include DEFINE_SIMPLE_EXCEPTION(TTXTParseError, SubtitleFormatParseError, "subtitle_io/parse/ttxt") @@ -54,9 +51,7 @@ TTXTSubtitleFormat::TTXTSubtitleFormat() } std::vector TTXTSubtitleFormat::GetReadWildcards() const { - std::vector formats; - formats.push_back("ttxt"); - return formats; + return {"ttxt"}; } std::vector TTXTSubtitleFormat::GetWriteWildcards() const { diff --git a/src/subtitle_format_txt.cpp b/src/subtitle_format_txt.cpp index a56002356..2e0bd98c3 100644 --- a/src/subtitle_format_txt.cpp +++ b/src/subtitle_format_txt.cpp @@ -40,11 +40,8 @@ #include "options.h" #include "text_file_reader.h" #include "text_file_writer.h" -#include "utils.h" #include "version.h" -#include - #include #include diff --git a/src/text_file_reader.cpp b/src/text_file_reader.cpp index a4885b9c5..972526a36 100644 --- a/src/text_file_reader.cpp +++ b/src/text_file_reader.cpp @@ -19,7 +19,6 @@ #include #include -#include #include #include #include diff --git a/src/text_file_writer.cpp b/src/text_file_writer.cpp index 2de9018c1..b77af0942 100644 --- a/src/text_file_writer.cpp +++ b/src/text_file_writer.cpp @@ -28,7 +28,6 @@ #include #include -#include TextFileWriter::TextFileWriter(agi::fs::path const& filename, std::string encoding) : file(new agi::io::Save(filename, true)) diff --git a/src/time_range.h b/src/time_range.h index e4e25e863..6c270f07d 100644 --- a/src/time_range.h +++ b/src/time_range.h @@ -27,8 +27,7 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file time_range.h -/// @ingroup audio_ui +#include /// @class TimeRange /// @brief Represents an immutable range of time diff --git a/src/timeedit_ctrl.cpp b/src/timeedit_ctrl.cpp index 1e0eb1051..20aed53e8 100644 --- a/src/timeedit_ctrl.cpp +++ b/src/timeedit_ctrl.cpp @@ -43,8 +43,6 @@ #include "project.h" #include "utils.h" -#include -#include #include #include diff --git a/src/toggle_bitmap.cpp b/src/toggle_bitmap.cpp index abf21e1d8..71de3ca57 100644 --- a/src/toggle_bitmap.cpp +++ b/src/toggle_bitmap.cpp @@ -32,16 +32,15 @@ /// @ingroup custom_control /// -#include -#include -#include - #include "toggle_bitmap.h" #include "command/command.h" -#include "include/aegisub/context.h" #include "tooltip_manager.h" +#include +#include +#include + ToggleBitmap::ToggleBitmap(wxWindow *parent, agi::Context *context, const char *cmd_name, int icon_size, const char *ht_ctx, wxSize const& size) : wxControl(parent, -1, wxDefaultPosition, wxDefaultSize, wxSUNKEN_BORDER) , context(context) diff --git a/src/toolbar.cpp b/src/toolbar.cpp index 96130643f..d0d5c86df 100644 --- a/src/toolbar.cpp +++ b/src/toolbar.cpp @@ -20,18 +20,15 @@ #include "command/command.h" #include "compat.h" -#include "include/aegisub/context.h" #include "include/aegisub/hotkey.h" #include "libresrc/libresrc.h" #include "options.h" #include "retina_helper.h" -#include "utils.h" #include #include #include #include -#include #include #include diff --git a/src/utils.cpp b/src/utils.cpp index 24aacb45f..4c275f721 100644 --- a/src/utils.cpp +++ b/src/utils.cpp @@ -35,7 +35,6 @@ #include "utils.h" #include "compat.h" -#include "frame_main.h" #include "options.h" #include "retina_helper.h" @@ -46,7 +45,7 @@ #ifdef __UNIX__ #include #endif -#include +#include #include #include #include diff --git a/src/utils.h b/src/utils.h index 34738f3da..b6555a839 100644 --- a/src/utils.h +++ b/src/utils.h @@ -27,29 +27,18 @@ // // Aegisub Project http://www.aegisub.org/ -/// @file utils.h -/// @see utils.cpp -/// @ingroup utility -/// - #pragma once #include -#include #include -#include -#include -#include +#include -#include -#include -#include -#include +#include +#include class wxMouseEvent; class wxWindow; -namespace cmd { class Command; } wxString PrettySize(int bytes); diff --git a/src/validators.cpp b/src/validators.cpp index 1486d91f5..c86c8bb03 100644 --- a/src/validators.cpp +++ b/src/validators.cpp @@ -17,7 +17,6 @@ #include "validators.h" #include "compat.h" -#include "utils.h" #include #include diff --git a/src/video_box.cpp b/src/video_box.cpp index 24663dcd6..b8a120e55 100644 --- a/src/video_box.cpp +++ b/src/video_box.cpp @@ -31,11 +31,9 @@ #include "ass_dialogue.h" #include "ass_file.h" -#include "command/command.h" #include "compat.h" #include "include/aegisub/context.h" #include "include/aegisub/toolbar.h" -#include "libresrc/libresrc.h" #include "options.h" #include "project.h" #include "selection_controller.h" diff --git a/src/video_controller.cpp b/src/video_controller.cpp index 66178b320..0e13a9173 100644 --- a/src/video_controller.cpp +++ b/src/video_controller.cpp @@ -34,25 +34,15 @@ #include "ass_time.h" #include "audio_controller.h" #include "compat.h" -#include "dialog_progress.h" -#include "dialogs.h" #include "include/aegisub/context.h" -#include "include/aegisub/video_provider.h" -#include "mkv_wrap.h" #include "options.h" #include "project.h" #include "selection_controller.h" -#include "subs_controller.h" #include "time_range.h" #include "async_video_provider.h" #include "utils.h" -#include "video_frame.h" -#include -#include -#include - -#include +#include VideoController::VideoController(agi::Context *c) : context(c) diff --git a/src/video_controller.h b/src/video_controller.h index d8a887091..27b5a4342 100644 --- a/src/video_controller.h +++ b/src/video_controller.h @@ -31,7 +31,6 @@ #include #include -#include #include #include @@ -39,7 +38,6 @@ class AssDialogue; class AsyncVideoProvider; struct SubtitlesProviderErrorEvent; -struct VideoFrame; struct VideoProviderErrorEvent; namespace agi { diff --git a/src/video_display.cpp b/src/video_display.cpp index 84b14c498..6d5344de4 100644 --- a/src/video_display.cpp +++ b/src/video_display.cpp @@ -45,19 +45,15 @@ #include "project.h" #include "retina_helper.h" #include "spline_curve.h" -#include "subs_controller.h" #include "utils.h" #include "video_out_gl.h" #include "video_controller.h" -#include "video_frame.h" #include "visual_tool.h" #include #include #include -#include -#include #include #include #include diff --git a/src/video_provider_dummy.cpp b/src/video_provider_dummy.cpp index 8c9db4491..8b3377080 100644 --- a/src/video_provider_dummy.cpp +++ b/src/video_provider_dummy.cpp @@ -38,13 +38,13 @@ #include "video_frame.h" #include -#include #include #include #include #include #include +#include #include #include diff --git a/src/video_provider_ffmpegsource.cpp b/src/video_provider_ffmpegsource.cpp index ea86e1a15..b8384ed23 100644 --- a/src/video_provider_ffmpegsource.cpp +++ b/src/video_provider_ffmpegsource.cpp @@ -36,18 +36,13 @@ #include "ffmpegsource_common.h" #include "include/aegisub/video_provider.h" -#include "compat.h" #include "options.h" #include "utils.h" -#include "video_controller.h" #include "video_frame.h" #include #include -#include -#include - namespace { /// @class FFmpegSourceVideoProvider /// @brief Implements video loading through the FFMS library. diff --git a/src/video_provider_manager.cpp b/src/video_provider_manager.cpp index 98842d6c1..3739a7293 100644 --- a/src/video_provider_manager.cpp +++ b/src/video_provider_manager.cpp @@ -22,7 +22,6 @@ #include #include -#include #include diff --git a/src/video_provider_yuv4mpeg.cpp b/src/video_provider_yuv4mpeg.cpp index d254e84ed..5694aca9b 100644 --- a/src/video_provider_yuv4mpeg.cpp +++ b/src/video_provider_yuv4mpeg.cpp @@ -34,19 +34,16 @@ #include "include/aegisub/video_provider.h" -#include "compat.h" #include "utils.h" #include "video_frame.h" #include -#include #include #include #include #include #include -#include #include #include diff --git a/src/visual_tool.cpp b/src/visual_tool.cpp index 6559441ac..5aecc92df 100644 --- a/src/visual_tool.cpp +++ b/src/visual_tool.cpp @@ -25,12 +25,9 @@ #include "ass_style.h" #include "ass_time.h" #include "include/aegisub/context.h" -#include "options.h" #include "selection_controller.h" -#include "utils.h" #include "video_controller.h" #include "video_display.h" -#include "visual_feature.h" #include "visual_tool_clip.h" #include "visual_tool_drag.h" #include "visual_tool_vector_clip.h" diff --git a/src/visual_tool.h b/src/visual_tool.h index c1d071b6a..c041b5909 100644 --- a/src/visual_tool.h +++ b/src/visual_tool.h @@ -27,11 +27,11 @@ #include #include -#include class AssDialogue; -class SubtitlesGrid; class VideoDisplay; +class wxMouseCaptureLostEvent; +class wxMouseEvent; class wxToolBar; namespace agi { struct Context; diff --git a/src/visual_tool_clip.cpp b/src/visual_tool_clip.cpp index 754f5ab9c..ea12f3fe8 100644 --- a/src/visual_tool_clip.cpp +++ b/src/visual_tool_clip.cpp @@ -23,10 +23,9 @@ #include "ass_dialogue.h" #include "include/aegisub/context.h" #include "selection_controller.h" -#include "utils.h" #include -#include +#include VisualToolClip::VisualToolClip(VideoDisplay *parent, agi::Context *context) : VisualTool(parent, context) diff --git a/src/visual_tool_cross.h b/src/visual_tool_cross.h index 637532c66..8172a40f8 100644 --- a/src/visual_tool_cross.h +++ b/src/visual_tool_cross.h @@ -19,8 +19,8 @@ /// @ingroup visual_ts /// -#include "visual_feature.h" #include "visual_tool.h" +#include "visual_feature.h" #include diff --git a/src/visual_tool_drag.cpp b/src/visual_tool_drag.cpp index 0e6d21306..c2a7dfd2b 100644 --- a/src/visual_tool_drag.cpp +++ b/src/visual_tool_drag.cpp @@ -26,7 +26,6 @@ #include "libresrc/libresrc.h" #include "options.h" #include "selection_controller.h" -#include "utils.h" #include "video_controller.h" #include "video_display.h" @@ -35,7 +34,6 @@ #include #include #include -#include #include diff --git a/src/visual_tool_drag.h b/src/visual_tool_drag.h index 70dade63f..d869d37e8 100644 --- a/src/visual_tool_drag.h +++ b/src/visual_tool_drag.h @@ -31,6 +31,7 @@ public: }; class wxBitmapButton; +class wxCommandEvent; class wxToolBar; /// @class VisualToolDrag diff --git a/src/visual_tool_rotatexy.cpp b/src/visual_tool_rotatexy.cpp index e3fc503e1..1e2ea62c8 100644 --- a/src/visual_tool_rotatexy.cpp +++ b/src/visual_tool_rotatexy.cpp @@ -22,6 +22,7 @@ #include #include +#include VisualToolRotateXY::VisualToolRotateXY(VideoDisplay *parent, agi::Context *context) : VisualTool(parent, context) diff --git a/src/visual_tool_rotatez.cpp b/src/visual_tool_rotatez.cpp index 6fb0bb3f2..4f8ba7ca8 100644 --- a/src/visual_tool_rotatez.cpp +++ b/src/visual_tool_rotatez.cpp @@ -20,10 +20,9 @@ #include "visual_tool_rotatez.h" -#include "utils.h" - #include #include +#include static const float deg2rad = 3.1415926536f / 180.f; static const float rad2deg = 180.f / 3.1415926536f; diff --git a/src/visual_tool_scale.cpp b/src/visual_tool_scale.cpp index 50f26844b..1a0a0a1de 100644 --- a/src/visual_tool_scale.cpp +++ b/src/visual_tool_scale.cpp @@ -18,11 +18,9 @@ /// @brief X/Y scaling visual typesetting tool /// @ingroup visual_ts -#include - #include "visual_tool_scale.h" -#include "utils.h" +#include VisualToolScale::VisualToolScale(VideoDisplay *parent, agi::Context *context) : VisualTool(parent, context) diff --git a/src/visual_tool_vector_clip.cpp b/src/visual_tool_vector_clip.cpp index 35c40b88b..a9d002a61 100644 --- a/src/visual_tool_vector_clip.cpp +++ b/src/visual_tool_vector_clip.cpp @@ -25,7 +25,6 @@ #include "libresrc/libresrc.h" #include "options.h" #include "selection_controller.h" -#include "utils.h" #include