Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion RavelCAPI
Submodule RavelCAPI updated 1 files
+1 −1 civita
12 changes: 11 additions & 1 deletion model/windowInformation.cc
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,11 @@ namespace minsky
HDC dc=BeginPaint(winfo.childWindowId, &ps);
BitBlt(dc, x, y, width,height,winfo.hdcMem,x,y,SRCCOPY);
EndPaint(winfo.childWindowId, &ps);
SetWindowPos(winfo.childWindowId,HWND_TOP,winfo.offsetLeft,winfo.offsetTop,winfo.childWidth,winfo.childHeight,0);
// Note: SetWindowPos was previously called here on every blit to keep the
// child window at HWND_TOP, but that fired WM_WINDOWPOSCHANGED on every
// paint which could cascade into further WM_PAINT messages and interact
// badly with screen-sharing hooks (e.g. Zoom). The window is already
// positioned correctly at creation time in WindowInformation().
Comment on lines +85 to +89
#elif defined(USE_X11)
static mutex blitting;
const lock_guard<mutex> lock(blitting);
Expand Down Expand Up @@ -159,6 +163,12 @@ namespace minsky
if (GetUpdateRect(hwnd,&r,false))
blit(*winfo, r.left, r.top, r.right-r.left, r.bottom-r.top);
}
else
// GWLP_USERDATA is zeroed in ~WindowInformation before the window is
// closed, so reaching here means the WindowInformation has already been
// torn down. Validate the rect so Windows stops generating WM_PAINT
// messages for a window that no longer has a backing buffer.
ValidateRect(hwnd, nullptr);
Comment on lines +166 to +171
return 0;
case WM_NCHITTEST:
return HTTRANSPARENT;
Expand Down
2 changes: 1 addition & 1 deletion schema/optional.h
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ namespace classdesc
void xsd_generate(xsd_generate_t& g, const string& d, const minsky::Optional<T>& a)
{
xsd_generate_t::Optional o(g,true);
T tmp; // a may be null
T tmp{}; // a may be null
xsd_generate(g,d,tmp);
}

Expand Down
2 changes: 1 addition & 1 deletion test/testMinsky.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1270,7 +1270,7 @@ TEST(TensorOps, evalOpEvaluate)

// renaming just the canvas variable should change it's type
canvas.item=stockVar;
if (auto v=canvas.item->variableCast())
if (canvas.item->variableCast())
{
canvas.renameItem("foo");
EXPECT_TRUE(canvas.item && canvas.item->variableCast());
Expand Down
2 changes: 1 addition & 1 deletion test/testPubTab.cc
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ TEST_F(PubTabSuite,removeSelf)
load("1Free.mky");
// send the Godley table to the pub tab
for (auto& i: model->items)
if (auto g=dynamic_cast<GodleyIcon*>(i.get()))
if (dynamic_cast<GodleyIcon*>(i.get()))
{
publicationTabs[0].items.emplace_back(i);
break;
Expand Down
Loading