Skip to content

Commit

Permalink
Fix build with Visual Studio
Browse files Browse the repository at this point in the history
I also fixed a compiler warning.
  • Loading branch information
jyrkive committed Feb 18, 2017
1 parent 0e1d6df commit 74aa2b6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/image_modifications.cpp
Expand Up @@ -520,7 +520,7 @@ std::pair<int,int> scale_into_modification::calculate_size(const surface& src) c

long double ratio = std::min(w / old_w, h / old_h);

return {old_w * ratio, old_h * ratio};
return {static_cast<int>(old_w * ratio), static_cast<int>(old_h * ratio)};
}

surface xbrz_modification::operator()(const surface& src) const
Expand Down
2 changes: 1 addition & 1 deletion src/image_modifications.hpp
Expand Up @@ -51,7 +51,7 @@ class modification_queue

private:
/// Map from a mod's priority() to the mods having that priority.
typedef std::map<int, std::vector<std::unique_ptr<modification>>, std::greater<int>> map_type;
typedef std::map<int, std::vector<std::shared_ptr<modification>>, std::greater<int>> map_type;
/// Map from a mod's priority() to the mods having that priority.
map_type priorities_;
};
Expand Down

0 comments on commit 74aa2b6

Please sign in to comment.