1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-10 12:32:20 +02:00

Autocomplete flashing fix

This commit is contained in:
Brian Fiete 2020-07-18 06:51:09 -07:00
parent af77825b9d
commit 55db457590

View file

@ -307,15 +307,16 @@ namespace IDE.ui
base.Draw(g);
float drawHeight = (mWantHeight != 0) ? mWantHeight : mHeight;
float boxWidth = mWidth - GS!(2) - mRightBoxAdjust;
if (mOwnsWindow)
{
using (g.PushColor(0x80000000))
g.DrawBox(DarkTheme.sDarkTheme.GetImage(DarkTheme.ImageIdx.DropShadow), GS!(2), GS!(2), mWidth - GS!(2) - mRightBoxAdjust, drawHeight - GS!(2));
g.DrawBox(DarkTheme.sDarkTheme.GetImage(DarkTheme.ImageIdx.DropShadow), GS!(2), GS!(2), boxWidth, drawHeight - GS!(2));
base.Draw(g);
using (g.PushColor(0xFFFFFFFF))
g.DrawBox(DarkTheme.sDarkTheme.GetImage(DarkTheme.ImageIdx.Menu), 0, 0, mWidth - GS!(8) - mRightBoxAdjust, drawHeight - GS!(8));
g.DrawBox(DarkTheme.sDarkTheme.GetImage(DarkTheme.ImageIdx.Menu), 0, 0, boxWidth - GS!(6), drawHeight - GS!(8));
}
g.SetFont(IDEApp.sApp.mCodeFont);
@ -533,6 +534,8 @@ namespace IDE.ui
int windowHeight = (int)(mWantHeight + Math.Max(0, mDocHeight - GS!(32)));
Debug.WriteLine("Updating {} {}", windowWidth, mRightBoxAdjust);
mIgnoreMove++;
if (mAutoComplete.mInvokeWidget != null)
mAutoComplete.mInvokeWidget.mIgnoreMove++;
@ -1734,7 +1737,9 @@ namespace IDE.ui
mAutoCompleteListWidget.mOwnsWindow = !IsInPanel();
mAutoCompleteListWidget.mAutoFocus = IsInPanel();
int32 windowWidth = (int32)mAutoCompleteListWidget.mMaxWidth;
windowWidth += (int32)mAutoCompleteListWidget.mDocWidth;
if (mAutoCompleteListWidget.mRightBoxAdjust != 0)
windowWidth += (int32)mAutoCompleteListWidget.mRightBoxAdjust; // - GS!(16);
//windowWidth += (int32)mAutoCompleteListWidget.mDocWidth;
windowWidth += GS!(16);
int32 contentHeight = (int32)(visibleCount * mAutoCompleteListWidget.mItemSpacing);