Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 03436e9c authored by Steven Thomas's avatar Steven Thomas Committed by Android (Google) Code Review
Browse files

Merge "Ignore callbacks from the non-active hardware composer"

parents 274f0bb8 3cfac284
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -318,6 +318,10 @@ int DisplayService::UpdateActiveDisplaySurfaces() {
  return hardware_composer_.SetDisplaySurfaces(std::move(visible_surfaces));
}

void DisplayService::OnHardwareComposerRefresh() {
  hardware_composer_.OnHardwareComposerRefresh();
}

void DisplayService::SetDisplayConfigurationUpdateNotifier(
    DisplayConfigurationUpdateNotifier update_notifier) {
  update_notifier_ = update_notifier;
+2 −0
Original line number Diff line number Diff line
@@ -68,6 +68,8 @@ class DisplayService : public pdx::ServiceBase<DisplayService> {
    }
  }

  void OnHardwareComposerRefresh();

 private:
  friend BASE;
  friend DisplaySurface;
+4 −0
Original line number Diff line number Diff line
@@ -1287,6 +1287,10 @@ void HardwareComposer::HwcHotplug(hwc2_callback_data_t /*callbackData*/,
  // TODO(eieio): implement display hotplug callbacks.
}

void HardwareComposer::OnHardwareComposerRefresh() {
  // TODO(steventhomas): Handle refresh.
}

void HardwareComposer::SetBacklightBrightness(int brightness) {
  if (backlight_brightness_fd_) {
    std::array<char, 32> text;
+2 −0
Original line number Diff line number Diff line
@@ -224,6 +224,8 @@ class HardwareComposer {

  Compositor* GetCompositor() { return &compositor_; }

  void OnHardwareComposerRefresh();

 private:
  int32_t EnableVsync(bool enabled);

+1 −0
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@ class VrFlinger {

  void EnterVrMode();
  void ExitVrMode();
  void OnHardwareComposerRefresh();

 private:
  std::thread displayd_thread_;
Loading