[nostalgia/core/studio] Replace ox::Error catch with ox::Exception catch

This commit is contained in:
Gary Talent 2021-07-17 12:25:47 -05:00
parent eb39c6aaf0
commit 5a52d322b2
2 changed files with 2 additions and 8 deletions

View File

@ -391,10 +391,6 @@ void TileSheetClipboard::addPixel(int color) {
m_pixels.push_back(color);
}
void TileSheetClipboard::clear() {
m_pixels.clear();
}
bool TileSheetClipboard::empty() const {
return m_pixels.empty();
}
@ -591,7 +587,7 @@ void SheetData::setPalette(const studio::Context *ctx, QString palPath) {
std::unique_ptr<NostalgiaPalette> npal;
try {
npal = ctx->project->loadObj<NostalgiaPalette>(palPath);
} catch (ox::Error) {
} catch (ox::Exception&) {
qWarning() << "Could not open palette" << palPath;
}
if (npal) {
@ -895,7 +891,7 @@ void TileSheetEditor::exportFile() {
std::unique_ptr<NostalgiaPalette> npal;
try {
npal = m_ctx->project->loadObj<NostalgiaPalette>(palPath);
} catch (ox::Error) {
} catch (ox::Exception&) {
qWarning() << "Could not open palette" << palPath;
// TODO: message box to notify of failure
}

View File

@ -79,8 +79,6 @@ struct TileSheetClipboard {
public:
void addPixel(int color);
void clear();
[[nodiscard]] bool empty() const;
void pastePixels(common::Point pt, QVector<int> *tgt, int tgtColumns) const;