This takes care of the divider visibility regardless of when
and how the tabs are created, fixing both mentioned issues.
GitOrigin-RevId: 9907327b4c817db4f134d3f2cdd8a3f8a3163287
This reverts commit df7e05f7
The commit is reverted because the issue is fixed on the JBR
side by JBR-7481.
GitOrigin-RevId: 830d8a6d02c17487e8dd890de72be4cde8934ab9
This reverts commit ae713777d3a3dc9106842b39c626ac80abff9bfc.
The commit is reverted because a proper fix is done
on the JBR side, JBR-7484.
GitOrigin-RevId: 6827780c5f6fd38d80a1f9ca8142f28b1339d628
Since this is a computable property, to be on the safe side,
read it only once. This can be very helpful if ever in the future
it starts returning different values due to some bug,
for example. Then we can be sure that the used value and
the logged value are the same.
GitOrigin-RevId: 0ca8e953c353ea4405f0d189399f11ea08a9aacf
Because it's used in initLux, it's accessed at an early delicate stage.
But UiUtil is a huge class that invokes a lot of stuff in its static init,
and some of that stuff (JBInsets.create) involves scaling, which isn't
initialized here yet.
Invoking preload() from there was a mistake. It's not guaranteed
that all data needed to compute the scaling factors is ready.
And we don't really need it at that stage.
To fix this properly, we extract just the part of UiUtil that's
used in initLux. It isn't even a public API. And as a bonus,
it'll be faster here too, as we don't need to load that huge class
anymore.
GitOrigin-RevId: 6ad6bbb24c7753cfb27f148e405a31117ad74964
Otherwise, the first resize is almost guaranteed to be missed,
as by the time the collector starts, the first value is likely
to be already emitted.
And add the usual check() around tryEmit().
GitOrigin-RevId: 2242ca01325fc7dc30d3593b4a62f0bf1f0b28d4
Note that
ToolWindowManagerEventType.UnregisterToolWindow
can't be used here, as it's not guaranteed to be fired,
for example, when the plugin is unloaded.
The separate callback toolWindowUnregistered
seems to always work.
GitOrigin-RevId: 3cc70527e9bf8cf2bc8e2fee525781d7d18e2e12
Don't access the windowsSize map twice to check the old value.
Use ConcurrentHashMap for collectors, as the tool window
manager isn't guaranteed to always fire events on the EDT.
This is especially true for the "unregister" events
that we're about to start handling.
Replace getOrPut with computeIfAbsent, as getOrPut
doesn't guarantee that the supplied function isn't called
if the map already contains the key.
GitOrigin-RevId: bfec867346030603aef8729e96afe2e74cc679b2
Extract the per-window collector into a separate class.
We'll need it to implement the functionality to cancel
collectors on window unregistration.
Add names to collector coroutines.
GitOrigin-RevId: 41a7cd7b1d03f460be9e7c73c63814a9e62cc97c
Show it for top-level remote group only.
It could be shown for local branches if grouping by repo and by directory were enabled
GitOrigin-RevId: c22b8e4c21ebcb01e318e7deea87554431e9b263