Revert "Update previews on preference change (#9507)"

The referenced commit lead to performance issues and possibly
crashes in some cases when saving preferences. Thanks to Guillaume
for discovering the issues. See #9828 for more discussion.

I hope to come up with a better fix for #9507.

This reverts commit 390ae05444.
This commit is contained in:
Scott Kostyshak 2015-11-11 18:06:07 -05:00
parent 520dde2038
commit 358745d0e3
3 changed files with 0 additions and 13 deletions

View File

@ -344,15 +344,6 @@ void BufferList::recordCurrentAuthor(Author const & author)
} }
void BufferList::updatePreviews()
{
BufferStorage::iterator it = bstore.begin();
BufferStorage::iterator end = bstore.end();
for (; it != end; ++it)
(*it)->updatePreviews();
}
int BufferList::bufferNum(FileName const & fname) const int BufferList::bufferNum(FileName const & fname) const
{ {
FileNameList const buffers(fileNames()); FileNameList const buffers(fileNames());

View File

@ -115,8 +115,6 @@ public:
//@{ //@{
/// reset current author for all buffers /// reset current author for all buffers
void recordCurrentAuthor(Author const & author); void recordCurrentAuthor(Author const & author);
/// update previews for all buffers, e.g. for Prefs update
void updatePreviews();
/// Call changed() on all buffers, internal or not /// Call changed() on all buffers, internal or not
void changed(bool update_metrics) const; void changed(bool update_metrics) const;
/// emergency save for all buffers /// emergency save for all buffers

View File

@ -3371,8 +3371,6 @@ void GuiPreferences::dispatchParams()
update_screen_font_ = false; update_screen_font_ = false;
} }
theBufferList().updatePreviews();
// The Save button has been pressed // The Save button has been pressed
if (isClosing()) if (isClosing())
dispatch(FuncRequest(LFUN_PREFERENCES_SAVE)); dispatch(FuncRequest(LFUN_PREFERENCES_SAVE));