forked from mia/Aegisub
Only refresh the time columns of the subtitle grid when times change
Originally committed to SVN as r4913.
This commit is contained in:
parent
27cb511556
commit
e1e98d0ddd
2 changed files with 10 additions and 5 deletions
|
@ -71,9 +71,6 @@ class BaseGrid : public wxWindow, public BaseSelectionController<AssDialogue> {
|
||||||
/// DOCME
|
/// DOCME
|
||||||
int lineHeight;
|
int lineHeight;
|
||||||
|
|
||||||
/// DOCME
|
|
||||||
int colWidth[16];
|
|
||||||
|
|
||||||
/// DOCME
|
/// DOCME
|
||||||
int lastRow;
|
int lastRow;
|
||||||
|
|
||||||
|
@ -112,6 +109,9 @@ class BaseGrid : public wxWindow, public BaseSelectionController<AssDialogue> {
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
|
/// DOCME
|
||||||
|
int colWidth[16];
|
||||||
|
|
||||||
/// DOCME
|
/// DOCME
|
||||||
FrameMain *parentFrame;
|
FrameMain *parentFrame;
|
||||||
|
|
||||||
|
|
|
@ -127,9 +127,14 @@ void SubtitlesGrid::OnCommit(int type) {
|
||||||
else if (type == AssFile::COMMIT_UNDO)
|
else if (type == AssFile::COMMIT_UNDO)
|
||||||
UpdateMaps(true);
|
UpdateMaps(true);
|
||||||
|
|
||||||
if (type != AssFile::COMMIT_TIMES)
|
if (type == AssFile::COMMIT_TIMES) {
|
||||||
|
// Refresh just the audio times columns
|
||||||
|
RefreshRect(wxRect(colWidth[0] + colWidth[1], 0, colWidth[2] + colWidth[3], GetClientSize().GetHeight()), false);
|
||||||
|
}
|
||||||
|
else {
|
||||||
SetColumnWidths();
|
SetColumnWidths();
|
||||||
Refresh(false);
|
Refresh(false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// @brief Popup menu
|
/// @brief Popup menu
|
||||||
|
|
Loading…
Reference in a new issue