1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-02-21 00:39:58 +00:00

Use make_unique

This commit is contained in:
Evil Eye 2022-08-31 21:16:03 +02:00
parent f4bc06604a
commit 3c8943c876
2 changed files with 2 additions and 3 deletions

View File

@ -125,8 +125,7 @@ namespace MWClass
MWWorld::LiveCellRef<ESM::Potion> *ref =
ptr.get<ESM::Potion>();
std::unique_ptr<MWWorld::Action> action (
new MWWorld::ActionApply (ptr, ref->mBase->mId));
auto action = std::make_unique<MWWorld::ActionApply>(ptr, ref->mBase->mId);
action->setSound ("Drink");

View File

@ -34,7 +34,7 @@ namespace MWGui
, mCurrentFilter(FilterType::ByName)
, mModel(nullptr)
, mSortModel(nullptr)
, mAlchemy(new MWMechanics::Alchemy())
, mAlchemy(std::make_unique<MWMechanics::Alchemy>())
, mApparatus (4)
, mIngredients (4)
{