Giter VIP home page Giter VIP logo

Comments (1)

mdhiggins avatar mdhiggins commented on June 9, 2024

BoundingRectangleProperty shouldn't catch new items as that would have no impact on the rectangle size when windows are opened. BoundingRectangleProperty only catches when the UI occasionally redraws the taskbar and moves things back to the original position. When new items are added to the task bar the size does not change (its not sized to fit its children but instead sized based around its siblings). Adjusting to the width to fit the children triggers a redraw and messes everything up, tried that.

I've tried a number of UIAutomation events and properties and have not been able to find a better solution. I've tried watching the BoundingRectangleProperty of a number of elements (the ideal one would be the invisible accessibility element at the end of the list of children) but this doesn't trigger any events, none of the child task bar button elements do. I've tried AddStructureChangedEventHandler, I've tried BoundingRectangleProperty, PositionInSetProperty all with no success. I also have not found a good way to filter out the noise for the closed event directly but that's partly why the old positions are cached so that the position loop can quickly terminate without a ton of calculations when those false calls happen.

I'm open to any suggestions but I think I've gone through most of the available events that Microsoft has documented in UIAutomation and can't find one that works better than the current solution

from centertaskbar.

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.