mirror of
https://github.com/openharmony/windowmanager.git
synced 2026-07-21 04:25:28 -04:00
@@ -41,6 +41,7 @@ public:
|
||||
sptr<WindowNodeContainer> GetWindowNodeContainer(DisplayId displayId);
|
||||
sptr<WindowNodeContainer> CreateWindowNodeContainer(sptr<DisplayInfo> displayInfo);
|
||||
sptr<WindowNode> GetWindowNode(uint32_t windowId) const;
|
||||
void GetBackgroundNodesByScreenId(ScreenId screenGroupId, std::vector<sptr<WindowNode>>& windowNodes) const;
|
||||
|
||||
WMError SaveWindow(const sptr<WindowNode>& node);
|
||||
void AddDeathRecipient(sptr<WindowNode> node);
|
||||
@@ -84,7 +85,7 @@ public:
|
||||
void SetBrightness(uint32_t windowId, float brightness);
|
||||
void HandleKeepScreenOn(uint32_t windowId, bool requireLock);
|
||||
void UpdateFocusableProperty(uint32_t windowId);
|
||||
void SetMaxAppWindowNumber(int windowNum);
|
||||
void SetMaxAppWindowNumber(uint32_t windowNum);
|
||||
WMError GetModeChangeHotZones(DisplayId displayId,
|
||||
ModeChangeHotZones& hotZones, const ModeChangeHotZonesConfig& config);
|
||||
std::vector<DisplayId> GetAllDisplayIds() const;
|
||||
@@ -100,6 +101,7 @@ public:
|
||||
sptr<WindowNode> FindDialogCallerNode(WindowType type, sptr<IRemoteObject> token);
|
||||
bool CheckMultiDialogWindows(WindowType type, sptr<IRemoteObject> token);
|
||||
bool HasPrivateWindow(DisplayId displayId);
|
||||
|
||||
private:
|
||||
void OnRemoteDied(const sptr<IRemoteObject>& remoteObject);
|
||||
WMError DestroyWindowInner(sptr<WindowNode>& node);
|
||||
|
||||
@@ -88,8 +88,15 @@ WMError WindowDumper::DumpScreenGroupWindowInfo(ScreenId screenGroupId,
|
||||
<< std::endl;
|
||||
std::vector<sptr<WindowNode>> windowNodes;
|
||||
windowNodeContainer->TraverseContainer(windowNodes);
|
||||
uint32_t zOrder = windowNodes.size();
|
||||
int zOrder = windowNodes.size();
|
||||
windowRoot_->GetBackgroundNodesByScreenId(screenGroupId, windowNodes);
|
||||
for (auto& windowNode : windowNodes) {
|
||||
if (zOrder < 0) {
|
||||
zOrder = 0;
|
||||
} else if (zOrder == 0) {
|
||||
oss << "---------------------------------------------------------------------------------------"
|
||||
<< std::endl;
|
||||
}
|
||||
if (windowNode == nullptr) {
|
||||
--zOrder;
|
||||
break;
|
||||
|
||||
@@ -144,6 +144,16 @@ sptr<WindowNode> WindowRoot::GetWindowNode(uint32_t windowId) const
|
||||
return iter->second;
|
||||
}
|
||||
|
||||
void WindowRoot::GetBackgroundNodesByScreenId(ScreenId screenGroupId, std::vector<sptr<WindowNode>>& windowNodes) const
|
||||
{
|
||||
for (const auto& it : windowNodeMap_) {
|
||||
if (it.second && screenGroupId == DisplayManagerServiceInner::GetInstance().GetScreenGroupIdByDisplayId(
|
||||
it.second->GetDisplayId()) && !it.second->currentVisibility_) {
|
||||
windowNodes.push_back(it.second);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
sptr<WindowNode> WindowRoot::FindWindowNodeWithToken(const sptr<IRemoteObject>& token) const
|
||||
{
|
||||
if (token == nullptr) {
|
||||
@@ -1308,7 +1318,7 @@ bool WindowRoot::HasPrivateWindow(DisplayId displayId)
|
||||
return container != nullptr ? container->HasPrivateWindow() : false;
|
||||
}
|
||||
|
||||
void WindowRoot::SetMaxAppWindowNumber(int windowNum)
|
||||
void WindowRoot::SetMaxAppWindowNumber(uint32_t windowNum)
|
||||
{
|
||||
maxAppWindowNumber_ = windowNum;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user