Enable official build (#11847)

* Updated libchromiumcontent submodule

* Use same LTO settings as libcc

* Use whole program optimization, favour speed, remove redundancies

* Don't use variable template as it confuses LTCG

* Use lld and ThinLTO only on limited set of architectures
This commit is contained in:
Aleš Pergl 2018-02-08 20:26:23 +01:00 committed by Charles Kerr
parent 8b9b1e5595
commit efb44050db
4 changed files with 25 additions and 10 deletions

View file

@ -174,7 +174,7 @@ void DesktopNotificationController::AnimateAll() {
if (SystemParametersInfo(SPI_GETWORKAREA, 0, &work_area, 0)) {
ScreenMetrics metrics;
POINT origin = { work_area.right,
work_area.bottom - metrics.Y(toast_margin_<int>) };
work_area.bottom - metrics.Y(toast_margin_) };
auto hdwp =
BeginDeferWindowPos(static_cast<int>(instances_.size()));
@ -231,7 +231,7 @@ void DesktopNotificationController::AnimateAll() {
// Set new toast positions
if (!instances_.empty()) {
ScreenMetrics metrics;
auto margin = metrics.Y(toast_margin_<int>);
auto margin = metrics.Y(toast_margin_);
int target_pos = 0;
for (auto&& inst : instances_) {
@ -305,7 +305,7 @@ void DesktopNotificationController::CreateToast(NotificationLink&& data) {
auto toast = Toast::Get(item.hwnd);
toast_pos = toast->GetVerticalPosition() +
toast->GetHeight() +
scr.Y(toast_margin_<int>);
scr.Y(toast_margin_);
}
instances_.push_back({ hwnd, move(data) });

View file

@ -36,8 +36,7 @@ class DesktopNotificationController {
TimerID_Animate = 1
};
template<typename T>
static constexpr T toast_margin_ = 20;
static constexpr int toast_margin_ = 20;
// Wrapper around `NotificationData` which makes sure that
// the `controller` member is cleared when the controller object