mirror of https://github.com/odrling/Aegisub
parent
be77dc8307
commit
0aa553eb7c
|
@ -41,6 +41,10 @@
|
||||||
#include "ass_file.h"
|
#include "ass_file.h"
|
||||||
#include "include/aegisub/context.h"
|
#include "include/aegisub/context.h"
|
||||||
|
|
||||||
|
#ifndef AGI_PRE
|
||||||
|
#include <algorithm>
|
||||||
|
#endif
|
||||||
|
|
||||||
static inline std::list<AssExportFilter*>::const_iterator filter_list_begin() {
|
static inline std::list<AssExportFilter*>::const_iterator filter_list_begin() {
|
||||||
return AssExportFilterChain::GetFilterList()->begin();
|
return AssExportFilterChain::GetFilterList()->begin();
|
||||||
}
|
}
|
||||||
|
|
|
@ -734,7 +734,7 @@ void AudioDisplay::ReloadRenderingSettings()
|
||||||
// FFTW is so fast we can afford to upgrade quality by two levels
|
// FFTW is so fast we can afford to upgrade quality by two levels
|
||||||
spectrum_quality += 2;
|
spectrum_quality += 2;
|
||||||
#endif
|
#endif
|
||||||
spectrum_quality = mid(0LL, spectrum_quality, 5LL);
|
spectrum_quality = mid<int64_t>(0, spectrum_quality, 5);
|
||||||
|
|
||||||
// Quality indexes: 0 1 2 3 4 5
|
// Quality indexes: 0 1 2 3 4 5
|
||||||
int spectrum_width[] = {8, 9, 9, 9, 10, 11};
|
int spectrum_width[] = {8, 9, 9, 9, 10, 11};
|
||||||
|
|
|
@ -88,7 +88,7 @@ namespace {
|
||||||
inline void get_if_right_type(lua_State *L, int &def)
|
inline void get_if_right_type(lua_State *L, int &def)
|
||||||
{
|
{
|
||||||
if (lua_isnumber(L, -1))
|
if (lua_isnumber(L, -1))
|
||||||
def = std::max(lua_tointeger(L, -1), def);
|
def = std::max<int>(lua_tointeger(L, -1), def);
|
||||||
}
|
}
|
||||||
|
|
||||||
inline void get_if_right_type(lua_State *L, bool &def)
|
inline void get_if_right_type(lua_State *L, bool &def)
|
||||||
|
|
|
@ -22,6 +22,7 @@
|
||||||
#ifndef AGI_PRE
|
#ifndef AGI_PRE
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
#include <vector>
|
||||||
|
|
||||||
#include <wx/bitmap.h>
|
#include <wx/bitmap.h>
|
||||||
#include <wx/string.h>
|
#include <wx/string.h>
|
||||||
|
|
|
@ -397,7 +397,7 @@ void KaraokeLineMatchDisplay::IncreaseSourceMatch()
|
||||||
|
|
||||||
void KaraokeLineMatchDisplay::DecreaseSourceMatch()
|
void KaraokeLineMatchDisplay::DecreaseSourceMatch()
|
||||||
{
|
{
|
||||||
source_sel_length = std::max(source_sel_length, 1u) - 1;
|
source_sel_length = std::max<size_t>(source_sel_length, 1) - 1;
|
||||||
Refresh(true);
|
Refresh(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -409,7 +409,7 @@ void KaraokeLineMatchDisplay::IncreseDestinationMatch()
|
||||||
|
|
||||||
void KaraokeLineMatchDisplay::DecreaseDestinationMatch()
|
void KaraokeLineMatchDisplay::DecreaseDestinationMatch()
|
||||||
{
|
{
|
||||||
destination_sel_length = std::max(destination_sel_length, 1u) - 1;
|
destination_sel_length = std::max<size_t>(destination_sel_length, 1) - 1;
|
||||||
Refresh(true);
|
Refresh(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -38,6 +38,7 @@
|
||||||
#include <wx/dataview.h>
|
#include <wx/dataview.h>
|
||||||
#include <wx/regex.h>
|
#include <wx/regex.h>
|
||||||
|
|
||||||
|
#include <list>
|
||||||
#include <set>
|
#include <set>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -441,14 +441,14 @@ Vector2D VisualToolBase::GetLinePosition(AssDialogue *diag) {
|
||||||
x = margin[0];
|
x = margin[0];
|
||||||
else if (hor == 1)
|
else if (hor == 1)
|
||||||
x = (script_res.X() + margin[0] - margin[1]) / 2;
|
x = (script_res.X() + margin[0] - margin[1]) / 2;
|
||||||
else if (hor == 2)
|
else
|
||||||
x = margin[1];
|
x = margin[1];
|
||||||
|
|
||||||
if (vert == 0)
|
if (vert == 0)
|
||||||
y = script_res.Y() - margin[2];
|
y = script_res.Y() - margin[2];
|
||||||
else if (vert == 1)
|
else if (vert == 1)
|
||||||
y = script_res.Y() / 2;
|
y = script_res.Y() / 2;
|
||||||
else if (vert == 2)
|
else
|
||||||
y = margin[2];
|
y = margin[2];
|
||||||
|
|
||||||
return Vector2D(x, y);
|
return Vector2D(x, y);
|
||||||
|
|
|
@ -24,6 +24,7 @@
|
||||||
|
|
||||||
#ifndef AGI_PRE
|
#ifndef AGI_PRE
|
||||||
#include <deque>
|
#include <deque>
|
||||||
|
#include <list>
|
||||||
#include <map>
|
#include <map>
|
||||||
#include <set>
|
#include <set>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
Loading…
Reference in New Issue