Changeset View
Changeset View
Standalone View
Standalone View
effects.h
Show First 20 Lines • Show All 351 Lines • ▼ Show 20 Line(s) | 332 | private: | |||
---|---|---|---|---|---|
352 | std::unique_ptr<WindowPropertyNotifyX11Filter> m_x11WindowPropertyNotify; | 352 | std::unique_ptr<WindowPropertyNotifyX11Filter> m_x11WindowPropertyNotify; | ||
353 | }; | 353 | }; | ||
354 | 354 | | |||
355 | class EffectWindowImpl : public EffectWindow | 355 | class EffectWindowImpl : public EffectWindow | ||
356 | { | 356 | { | ||
357 | Q_OBJECT | 357 | Q_OBJECT | ||
358 | public: | 358 | public: | ||
359 | explicit EffectWindowImpl(Toplevel *toplevel); | 359 | explicit EffectWindowImpl(Toplevel *toplevel); | ||
360 | virtual ~EffectWindowImpl(); | 360 | ~EffectWindowImpl() override; | ||
zzag: Please remove "virtual". | |||||
361 | 361 | | |||
362 | void enablePainting(int reason) override; | 362 | void enablePainting(int reason) override; | ||
363 | void disablePainting(int reason) override; | 363 | void disablePainting(int reason) override; | ||
364 | bool isPaintingEnabled() override; | 364 | bool isPaintingEnabled() override; | ||
365 | 365 | | |||
366 | void refWindow() override; | 366 | void refWindow() override; | ||
367 | void unrefWindow() override; | 367 | void unrefWindow() override; | ||
368 | 368 | | |||
369 | const EffectWindowGroup* group() const override; | 369 | const EffectWindowGroup* group() const override; | ||
370 | 370 | | |||
371 | bool isDeleted() const override; | ||||
372 | bool isMinimized() const override; | ||||
373 | double opacity() const override; | ||||
374 | bool hasAlpha() const override; | ||||
375 | | ||||
376 | QStringList activities() const override; | ||||
377 | int desktop() const override; | ||||
378 | QVector<uint> desktops() const override; | ||||
379 | int x() const override; | ||||
380 | int y() const override; | ||||
381 | int width() const override; | ||||
382 | int height() const override; | ||||
383 | | ||||
384 | QSize basicUnit() const override; | ||||
385 | QRect geometry() const override; | ||||
386 | | ||||
387 | QString caption() const override; | ||||
388 | | ||||
389 | QRect expandedGeometry() const override; | ||||
371 | QRegion shape() const override; | 390 | QRegion shape() const override; | ||
391 | int screen() const override; | ||||
392 | bool hasOwnShape() const override; // only for shadow effect, for now | ||||
393 | QPoint pos() const override; | ||||
394 | QSize size() const override; | ||||
395 | QRect rect() const override; | ||||
396 | | ||||
397 | bool isMovable() const override; | ||||
398 | bool isMovableAcrossScreens() const override; | ||||
399 | bool isUserMove() const override; | ||||
400 | bool isUserResize() const override; | ||||
401 | QRect iconGeometry() const override; | ||||
402 | | ||||
403 | bool isDesktop() const override; | ||||
404 | bool isDock() const override; | ||||
405 | bool isToolbar() const override; | ||||
406 | bool isMenu() const override; | ||||
407 | bool isNormalWindow() const override; | ||||
408 | bool isSpecialWindow() const override; | ||||
409 | bool isDialog() const override; | ||||
410 | bool isSplash() const override; | ||||
411 | bool isUtility() const override; | ||||
412 | bool isDropdownMenu() const override; | ||||
413 | bool isPopupMenu() const override; | ||||
414 | bool isTooltip() const override; | ||||
415 | bool isNotification() const override; | ||||
416 | bool isOnScreenDisplay() const override; | ||||
417 | bool isComboBox() const override; | ||||
418 | bool isDNDIcon() const override; | ||||
419 | bool skipsCloseAnimation() const override; | ||||
420 | | ||||
421 | bool acceptsFocus() const override; | ||||
422 | bool keepAbove() const override; | ||||
423 | bool keepBelow() const override; | ||||
424 | bool isModal() const override; | ||||
425 | bool isPopupWindow() const override; | ||||
426 | | ||||
427 | KWayland::Server::SurfaceInterface *surface() const override; | ||||
428 | bool isFullScreen() const override; | ||||
429 | bool isUnresponsive() const override; | ||||
430 | | ||||
431 | QRect contentsRect() const override; | ||||
432 | bool decorationHasAlpha() const override; | ||||
433 | QIcon icon() const override; | ||||
434 | QString windowClass() const override; | ||||
435 | NET::WindowType windowType() const override; | ||||
436 | bool isSkipSwitcher() const override; | ||||
437 | bool isCurrentTab() const override; | ||||
438 | QString windowRole() const override; | ||||
439 | | ||||
zzag: Missing whitespace between the type and "*". | |||||
440 | bool isManaged() const override; | ||||
441 | bool isWaylandClient() const override; | ||||
442 | bool isX11Client() const override; | ||||
443 | | ||||
372 | QRect decorationInnerRect() const override; | 444 | QRect decorationInnerRect() const override; | ||
373 | QByteArray readProperty(long atom, long type, int format) const override; | 445 | QByteArray readProperty(long atom, long type, int format) const override; | ||
374 | void deleteProperty(long atom) const override; | 446 | void deleteProperty(long atom) const override; | ||
375 | 447 | | |||
376 | EffectWindow* findModal() override; | 448 | EffectWindow* findModal() override; | ||
377 | EffectWindowList mainWindows() const override; | 449 | EffectWindowList mainWindows() const override; | ||
378 | 450 | | |||
379 | WindowQuadList buildQuads(bool force = false) const override; | 451 | WindowQuadList buildQuads(bool force = false) const override; | ||
Show All 16 Lines | |||||
396 | 468 | | |||
397 | void registerThumbnail(AbstractThumbnailItem *item); | 469 | void registerThumbnail(AbstractThumbnailItem *item); | ||
398 | QHash<WindowThumbnailItem*, QWeakPointer<EffectWindowImpl> > const &thumbnails() const { | 470 | QHash<WindowThumbnailItem*, QWeakPointer<EffectWindowImpl> > const &thumbnails() const { | ||
399 | return m_thumbnails; | 471 | return m_thumbnails; | ||
400 | } | 472 | } | ||
401 | QList<DesktopThumbnailItem*> const &desktopThumbnails() const { | 473 | QList<DesktopThumbnailItem*> const &desktopThumbnails() const { | ||
402 | return m_desktopThumbnails; | 474 | return m_desktopThumbnails; | ||
403 | } | 475 | } | ||
476 | | ||||
404 | private Q_SLOTS: | 477 | private Q_SLOTS: | ||
405 | void thumbnailDestroyed(QObject *object); | 478 | void thumbnailDestroyed(QObject *object); | ||
406 | void thumbnailTargetChanged(); | 479 | void thumbnailTargetChanged(); | ||
407 | void desktopThumbnailDestroyed(QObject *object); | 480 | void desktopThumbnailDestroyed(QObject *object); | ||
408 | private: | 481 | private: | ||
409 | void insertThumbnail(WindowThumbnailItem *item); | 482 | void insertThumbnail(WindowThumbnailItem *item); | ||
410 | Toplevel* toplevel; | 483 | Toplevel* toplevel; | ||
411 | Scene::Window* sw; // This one is used only during paint pass. | 484 | Scene::Window* sw; // This one is used only during paint pass. | ||
412 | QHash<int, QVariant> dataMap; | 485 | QHash<int, QVariant> dataMap; | ||
413 | QHash<WindowThumbnailItem*, QWeakPointer<EffectWindowImpl> > m_thumbnails; | 486 | QHash<WindowThumbnailItem*, QWeakPointer<EffectWindowImpl> > m_thumbnails; | ||
414 | QList<DesktopThumbnailItem*> m_desktopThumbnails; | 487 | QList<DesktopThumbnailItem*> m_desktopThumbnails; | ||
488 | bool managed = false; | ||||
489 | bool waylandClient; | ||||
490 | bool x11Client; | ||||
415 | }; | 491 | }; | ||
416 | 492 | | |||
417 | class EffectWindowGroupImpl | 493 | class EffectWindowGroupImpl | ||
418 | : public EffectWindowGroup | 494 | : public EffectWindowGroup | ||
419 | { | 495 | { | ||
420 | public: | 496 | public: | ||
421 | explicit EffectWindowGroupImpl(Group* g); | 497 | explicit EffectWindowGroupImpl(Group* g); | ||
422 | EffectWindowList members() const override; | 498 | EffectWindowList members() const override; | ||
Show All 9 Lines | 507 | public: | |||
432 | explicit EffectFrameImpl(EffectFrameStyle style, bool staticSize = true, QPoint position = QPoint(-1, -1), | 508 | explicit EffectFrameImpl(EffectFrameStyle style, bool staticSize = true, QPoint position = QPoint(-1, -1), | ||
433 | Qt::Alignment alignment = Qt::AlignCenter); | 509 | Qt::Alignment alignment = Qt::AlignCenter); | ||
434 | virtual ~EffectFrameImpl(); | 510 | virtual ~EffectFrameImpl(); | ||
435 | 511 | | |||
436 | void free() override; | 512 | void free() override; | ||
437 | void render(QRegion region = infiniteRegion(), double opacity = 1.0, double frameOpacity = 1.0) override; | 513 | void render(QRegion region = infiniteRegion(), double opacity = 1.0, double frameOpacity = 1.0) override; | ||
438 | Qt::Alignment alignment() const override; | 514 | Qt::Alignment alignment() const override; | ||
439 | void setAlignment(Qt::Alignment alignment) override; | 515 | void setAlignment(Qt::Alignment alignment) override; | ||
440 | const QFont& font() const override; | 516 | const QFont& font() const override; | ||
davidedmundson: Ignore these changes. Will fix in the morning. | |||||
441 | void setFont(const QFont& font) override; | 517 | void setFont(const QFont& font) override; | ||
442 | const QRect& geometry() const override; | 518 | const QRect& geometry() const override; | ||
443 | void setGeometry(const QRect& geometry, bool force = false) override; | 519 | void setGeometry(const QRect& geometry, bool force = false) override; | ||
444 | const QIcon& icon() const override; | 520 | const QIcon& icon() const override; | ||
445 | void setIcon(const QIcon& icon) override; | 521 | void setIcon(const QIcon& icon) override; | ||
446 | const QSize& iconSize() const override; | 522 | const QSize& iconSize() const override; | ||
447 | void setIconSize(const QSize& size) override; | 523 | void setIconSize(const QSize& size) override; | ||
448 | void setPosition(const QPoint& point) override; | 524 | void setPosition(const QPoint& point) override; | ||
▲ Show 20 Lines • Show All 118 Lines • Show Last 20 Lines |
Please remove "virtual".