~ci-train-bot/unity-system-compositor/unity-system-compositor-ubuntu-zesty-2649

« back to all changes in this revision

Viewing changes to tests/unit-tests/advanceable_timer.cpp

  • Committer: Alexandros Frantzis
  • Date: 2016-05-11 14:24:40 UTC
  • mfrom: (291 trunk)
  • mto: (291.1.1 0.6)
  • mto: This revision was merged to the branch mainline in revision 293.
  • Revision ID: alexandros.frantzis@canonical.com-20160511142440-3of4jozhe0s9fp5h
Sync with lp:unity-system-compositor

Show diffs side-by-side

added added

removed removed

Lines of Context:
140
140
        std::function<void()> const callback;
141
141
    };
142
142
 
143
 
    return create_alarm(std::make_shared<SimpleLockableCallback>(callback));
 
143
    return create_alarm(std::make_unique<SimpleLockableCallback>(callback));
144
144
}
145
145
 
146
146
std::unique_ptr<mir::time::Alarm> AdvanceableTimer::create_alarm(
147
 
    std::shared_ptr<mir::LockableCallback> const& callback)
 
147
    std::unique_ptr<mir::LockableCallback> callback)
148
148
{
149
149
    auto const adv_alarm =
150
 
        std::make_shared<detail::AdvanceableAlarm>(now(), callback);
 
150
        std::make_shared<detail::AdvanceableAlarm>(now(), std::move(callback));
151
151
 
152
152
    register_alarm(adv_alarm);
153
153