diff options
| author | iamgoofball <iamgoofball@gmail.com> | 2018-10-17 08:11:52 -0700 |
|---|---|---|
| committer | iamgoofball <iamgoofball@gmail.com> | 2018-10-17 08:11:52 -0700 |
| commit | b56421365ab75173facef74cdaf8d77d51df6d0f (patch) | |
| tree | 7128f12d08ea716b1c02a62156dce30240f0a28f /text_file_functions.cpp | |
| parent | d1347b2243c1595557d7b89d40eb88a68a94375b (diff) | |
APNG Support
Diffstat (limited to 'text_file_functions.cpp')
| -rw-r--r-- | text_file_functions.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/text_file_functions.cpp b/text_file_functions.cpp index 5b057a4b..a6ad4f76 100644 --- a/text_file_functions.cpp +++ b/text_file_functions.cpp @@ -360,6 +360,22 @@ QString AOApplication::get_sfx_suffix(QString sound_to_check) return sound_to_check + ".wav"; } +QString AOApplication::get_image_suffix(QString path_to_check) +{ + QString apng_check = path_to_check + ".apng"; + QString gif_check = path_to_check + ".gif"; + if(file_exists(apng_check)) + { + return path_to_check + ".apng"; + } + if(file_exists(gif_check)) + { + return path_to_check + ".gif"; + } + return path_to_check + ".gif"; +} + + //returns whatever is to the right of "search_line =" within target_tag and terminator_tag, trimmed //returns the empty string if the search line couldnt be found QString AOApplication::read_char_ini(QString p_char, QString p_search_line, QString target_tag, QString terminator_tag) |
