GithubHelp home page GithubHelp logo

Comments (11)

psifidotos avatar psifidotos commented on August 30, 2024 1

?I don't understand. Can't you simply repaint it using PreviewButton::update() ? Or you're testing it?
My main idea is we should only create the buttons one time.

big story... and update() was the wrong turn... I had to dig into the KDecoration2 code and the themes code in order to understand the logic behind single created buttons from PreviewButton...

The design is the following: PreviewButton creates its own decoration and client instances. By updating the client values and the initializing again the decoration then the button paints itself properly without any need for explicit update()....

So now with the last commit changing states for the buttons e.g. OnAllDesktops,Maximized/Restore, Different color scheme, Pressed, Hovered etc. etc... only updating the client is needed and passing to m_button the mouse events... Painting is done from the theme side without signaling it...

So this was a success... :) and now applet is almost at a full featured state...

from applet-window-buttons.

trmdi avatar trmdi commented on August 30, 2024 1

Now I've understood how you make the animation runs. Very interesting !

from applet-window-buttons.

trmdi avatar trmdi commented on August 30, 2024

Hmm... It only happens with BreezeEnhanced, and SierraBreeze and when drag from the maximize/unaximize button.
I think I should close this until you enable that button by default. If it still happens, then I would reopen it.

from applet-window-buttons.

psifidotos avatar psifidotos commented on August 30, 2024

please test again...
I cant reproduce with any of them..

also one more thing...
I think that the applet is almost ready, all settings I was thinking to support are present now in preferences

from applet-window-buttons.

trmdi avatar trmdi commented on August 30, 2024

Sorry, I meant "maximize/unmaximize" buttons.
You may have to repeat the steps several times.

from applet-window-buttons.

trmdi avatar trmdi commented on August 30, 2024

Another way to reproduce the bug is: quickly click on the maximize button repeatly

from applet-window-buttons.

psifidotos avatar psifidotos commented on August 30, 2024

Ok I reproduced but there is a big chance that this is totally upstream...

from applet-window-buttons.

trmdi avatar trmdi commented on August 30, 2024

Before it crashes, I see that PreviewButtonItem::createButton() is called many times. A bit weird.

from applet-window-buttons.

psifidotos avatar psifidotos commented on August 30, 2024

Before it crashes, I see that PreviewButtonItem::createButton() is called many times. A bit weird.

it isnt because I have no other way to update the buttons drawing based on client changes...
when the active window changes maximized/restore state all buttons are recreated...

from applet-window-buttons.

psifidotos avatar psifidotos commented on August 30, 2024

note quite yet... it is still crashing rarely, probably because during button destroying an animation has ended yet...

from applet-window-buttons.

trmdi avatar trmdi commented on August 30, 2024

--recreations for maximize and pin buttons are
not needed anymore but color scheme updating
in not ready yet (it stills needs recreations)
to work properly)

I don't understand. Can't you simply repaint it using PreviewButton::update() ? Or you're testing it?
My main idea is we should only create the buttons one time.

from applet-window-buttons.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.