Changeset View
Changeset View
Standalone View
Standalone View
abstract_client.h
Show First 20 Lines • Show All 613 Lines • ▼ Show 20 Line(s) | 324 | public: | |||
---|---|---|---|---|---|
614 | Layer layer() const override; | 614 | Layer layer() const override; | ||
615 | void updateLayer(); | 615 | void updateLayer(); | ||
616 | 616 | | |||
617 | void placeIn(const QRect &area); | 617 | void placeIn(const QRect &area); | ||
618 | 618 | | |||
619 | enum ForceGeometry_t { NormalGeometrySet, ForceGeometrySet }; | 619 | enum ForceGeometry_t { NormalGeometrySet, ForceGeometrySet }; | ||
620 | virtual void move(int x, int y, ForceGeometry_t force = NormalGeometrySet); | 620 | virtual void move(int x, int y, ForceGeometry_t force = NormalGeometrySet); | ||
621 | void move(const QPoint &p, ForceGeometry_t force = NormalGeometrySet); | 621 | void move(const QPoint &p, ForceGeometry_t force = NormalGeometrySet); | ||
622 | virtual void resizeWithChecks(int w, int h, ForceGeometry_t force = NormalGeometrySet) = 0; | 622 | virtual void resizeWithChecks(const QSize& s, ForceGeometry_t force = NormalGeometrySet) = 0; | ||
623 | void resizeWithChecks(const QSize& s, ForceGeometry_t force = NormalGeometrySet); | | |||
624 | void keepInArea(QRect area, bool partial = false); | 623 | void keepInArea(QRect area, bool partial = false); | ||
625 | virtual QSize minSize() const; | 624 | virtual QSize minSize() const; | ||
626 | virtual QSize maxSize() const; | 625 | virtual QSize maxSize() const; | ||
627 | virtual void setFrameGeometry(int x, int y, int w, int h, ForceGeometry_t force = NormalGeometrySet) = 0; | 626 | virtual void setFrameGeometry(const QRect &rect, ForceGeometry_t force = NormalGeometrySet) = 0; | ||
628 | void setFrameGeometry(const QRect &rect, ForceGeometry_t force = NormalGeometrySet); | | |||
629 | 627 | | |||
630 | /** | 628 | /** | ||
631 | * How to resize the window in order to obey constraints (mainly aspect ratios). | 629 | * How to resize the window in order to obey constraints (mainly aspect ratios). | ||
632 | */ | 630 | */ | ||
633 | enum SizeMode { | 631 | enum SizeMode { | ||
634 | SizeModeAny, | 632 | SizeModeAny, | ||
635 | SizeModeFixedW, ///< Try not to affect width | 633 | SizeModeFixedW, ///< Try not to affect width | ||
636 | SizeModeFixedH, ///< Try not to affect height | 634 | SizeModeFixedH, ///< Try not to affect height | ||
▲ Show 20 Lines • Show All 670 Lines • ▼ Show 20 Line(s) | 1304 | private: | |||
1307 | AbstractClient* cl; | 1305 | AbstractClient* cl; | ||
1308 | }; | 1306 | }; | ||
1309 | 1307 | | |||
1310 | inline void AbstractClient::move(const QPoint& p, ForceGeometry_t force) | 1308 | inline void AbstractClient::move(const QPoint& p, ForceGeometry_t force) | ||
1311 | { | 1309 | { | ||
1312 | move(p.x(), p.y(), force); | 1310 | move(p.x(), p.y(), force); | ||
1313 | } | 1311 | } | ||
1314 | 1312 | | |||
1315 | inline void AbstractClient::resizeWithChecks(const QSize& s, AbstractClient::ForceGeometry_t force) | | |||
1316 | { | | |||
1317 | resizeWithChecks(s.width(), s.height(), force); | | |||
1318 | } | | |||
1319 | | ||||
1320 | inline void AbstractClient::setFrameGeometry(const QRect &rect, ForceGeometry_t force) | | |||
1321 | { | | |||
1322 | setFrameGeometry(rect.x(), rect.y(), rect.width(), rect.height(), force); | | |||
1323 | } | | |||
1324 | | ||||
1325 | inline const QList<AbstractClient*>& AbstractClient::transients() const | 1313 | inline const QList<AbstractClient*>& AbstractClient::transients() const | ||
1326 | { | 1314 | { | ||
1327 | return m_transients; | 1315 | return m_transients; | ||
1328 | } | 1316 | } | ||
1329 | 1317 | | |||
1330 | inline bool AbstractClient::areGeometryUpdatesBlocked() const | 1318 | inline bool AbstractClient::areGeometryUpdatesBlocked() const | ||
1331 | { | 1319 | { | ||
1332 | return m_blockGeometryUpdates != 0; | 1320 | return m_blockGeometryUpdates != 0; | ||
Show All 29 Lines |