Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions libaegisub/common/cajun/reader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ UnknownElement Reader::ParseObject(Reader::TokenStream& tokenStream) {

MatchExpectedToken(Token::TOKEN_OBJECT_END, tokenStream);

return std::move(object);
return object;
}

UnknownElement Reader::ParseArray(Reader::TokenStream& tokenStream) {
Expand All @@ -296,7 +296,7 @@ UnknownElement Reader::ParseArray(Reader::TokenStream& tokenStream) {

MatchExpectedToken(Token::TOKEN_ARRAY_END, tokenStream);

return std::move(array);
return array;
}

UnknownElement Reader::ParseString(Reader::TokenStream& tokenStream) {
Expand Down
7 changes: 4 additions & 3 deletions src/MatroskaParser.c
Original file line number Diff line number Diff line change
Expand Up @@ -330,20 +330,20 @@ static void myvsnprintf(char *dest,unsigned dsize,const char *fmt,va_list ap)
}
if (*fmt == '0')
zero = 1;
state = 2;
state = 2; // fallthrough
case 2:
if (*fmt >= '0' && *fmt <= '9') {
width = width * 10 + *fmt++ - '0';
break;
}
state = 3;
state = 3; // fallthrough
case 3:
if (*fmt == 'l') {
++ll;
++fmt;
break;
}
state = 4;
state = 4; // fallthrough
case 4:
switch (*fmt) {
case 's':
Expand Down Expand Up @@ -2143,6 +2143,7 @@ static void parseBlockGroup(MatroskaFile *mf,uint64_t toplen,uint64_t timecode,
blockex:
cur = start = filepos(mf);
len = tmplen = toplen;
// fallthrough
case 0xa1: // Block
have_block = 1;

Expand Down
1 change: 1 addition & 0 deletions src/dialog_video_properties.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ bool update_video_properties(AssFile *file, const AsyncVideoProvider *new_provid
});
return true;
}
[[fallthrough]];

case MISMATCH_PROMPT:
int res = prompt(parent, ar_changed, sx, sy, vx, vy);
Expand Down
2 changes: 1 addition & 1 deletion src/hotkey.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ namespace {
auto hk_map = hotkey::inst->GetHotkeyMap();
bool changed = false;

for (size_t i = 0; added[i] && added[i][0]; ++i) {
for (size_t i = 0; added[i][0]; ++i) {
agi::hotkey::Combo combo(added[i][1], added[i][0], added[i][2]);

if (hotkey::inst->HasHotkey(combo.Context(), combo.Str()))
Expand Down
1 change: 1 addition & 0 deletions src/resolution_resampler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -240,6 +240,7 @@ void ResampleResolution(AssFile *ass, ResampleSettings settings) {
switch (settings.ar_mode) {
case ResampleARMode::RemoveBorder:
border_horizontally = !border_horizontally;
[[fallthrough]];
case ResampleARMode::AddBorder:
if (border_horizontally) // Wider/Shorter
settings.margin[LEFT] = settings.margin[RIGHT] = (settings.source_y * new_ar - settings.source_x) / 2;
Expand Down
9 changes: 6 additions & 3 deletions src/video_display.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -435,13 +435,15 @@ void VideoDisplay::OnMouseWheel(wxMouseEvent& event) {
bool swap = false;
switch (action) {
case SCALE_VIDEO_REV:
dir = -1; // fallthrough
dir = -1;
[[fallthrough]];
case SCALE_VIDEO:
SetWindowZoom(windowZoomValue + dir * .125 * (wheel / event.GetWheelDelta()));
break;

case ZOOM_VIDEO_REV:
dir = -1; // fallthrough
dir = -1;
[[fallthrough]];
case ZOOM_VIDEO:
{
double newZoomValue = videoZoomValue * (1 + dir * 0.125 * wheel / event.GetWheelDelta());
Expand All @@ -450,7 +452,8 @@ void VideoDisplay::OnMouseWheel(wxMouseEvent& event) {
break;

case PAN_VIDEO_SWAP:
swap = true; // Fallthrough
swap = true;
[[fallthrough]];
case PAN_VIDEO:
{
double distance = 5 * static_cast<double>(wheel) / event.GetWheelDelta();
Expand Down
2 changes: 1 addition & 1 deletion tests/tests/iconv.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ TEST(lagi_iconv, Conversions) {
TEST(lagi_iconv, Buffer) {
IconvWrapper conv("UTF-8", "UTF-16LE", false);
std::array<char, 4> buff;
buff.fill(0xFF);
buff.fill('\xFF');
std::span<char> sbuff(buff);
std::string_view src("", 1);

Expand Down
Loading