forked from mia/Aegisub
Update all selected rows in the vector clip tool rather than just the active line
This commit is contained in:
parent
b74130579f
commit
7553534d96
1 changed files with 9 additions and 2 deletions
|
@ -31,8 +31,10 @@
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#include "ass_dialogue.h"
|
#include "ass_dialogue.h"
|
||||||
|
#include "include/aegisub/context.h"
|
||||||
#include "libresrc/libresrc.h"
|
#include "libresrc/libresrc.h"
|
||||||
#include "main.h"
|
#include "main.h"
|
||||||
|
#include "selection_controller.h"
|
||||||
#include "utils.h"
|
#include "utils.h"
|
||||||
|
|
||||||
/// Button IDs
|
/// Button IDs
|
||||||
|
@ -199,13 +201,18 @@ void VisualToolVectorClip::MakeFeatures() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void VisualToolVectorClip::Save() {
|
void VisualToolVectorClip::Save() {
|
||||||
wxString tag = inverse ? "\\iclip" : "\\clip";
|
|
||||||
wxString value = "(";
|
wxString value = "(";
|
||||||
if (spline.GetScale() != 1)
|
if (spline.GetScale() != 1)
|
||||||
value += wxString::Format("%d,", spline.GetScale());
|
value += wxString::Format("%d,", spline.GetScale());
|
||||||
value += spline.EncodeToAss() + ")";
|
value += spline.EncodeToAss() + ")";
|
||||||
|
|
||||||
SetOverride(active_line, tag, value);
|
SubtitleSelection sel = c->selectionController->GetSelectedSet();
|
||||||
|
for (SubtitleSelection::iterator it = sel.begin(); it != sel.end(); ++it) {
|
||||||
|
// This check is technically not correct as it could be outside of an
|
||||||
|
// override block... but that's rather unlikely
|
||||||
|
bool has_iclip = (*it)->Text.find("\\iclip") != wxString::npos;
|
||||||
|
SetOverride(*it, has_iclip ? "\\iclip" : "\\clip", value);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void VisualToolVectorClip::UpdateDrag(feature_iterator feature) {
|
void VisualToolVectorClip::UpdateDrag(feature_iterator feature) {
|
||||||
|
|
Loading…
Reference in a new issue