8000 Dev by Alan-CRL · Pull Request #20 · Alan-CRL/Inkeys · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Dev #20

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
May 4, 2024
Merged

Dev #20

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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion 智绘教/HiEasyX/HiFunc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -263,4 +263,4 @@ namespace HiEasyX
for (int i = 0; i < img->getwidth() * img->getheight(); i++)
pBuf[i] |= 0xFF000000;
}
}
}
16 changes: 11 additions & 5 deletions 智绘教/HiEasyX/HiWindow.cpp
std::this_thread::sleep_for(std::chrono::milliseconds(1));
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
#include "HiCanvas.h"
#include "HiSysGUI/SysControlBase.h"

#include <chrono>

// Ԥ����Ϣ�ռ�
#define MSG_RESERVE_SIZE 100

Expand Down Expand Up @@ -143,7 +145,7 @@ namespace HiEasyX
{
while (g_vecWindows[index].isBusyProcessing)
{
HpSleep(1);
std::this_thread::sleep_for(std::chrono::milliseconds(1));
}
}
}
Expand All @@ -167,7 +169,7 @@ namespace HiEasyX
{
while (g_isInTask)
{
HpSleep(1);
}
}
}
Expand Down Expand Up @@ -734,7 +736,11 @@ namespace HiEasyX

ExMessage getmessage_win32(BYTE filter, HWND hWnd)
{
while (!IsNewMessage(filter, hWnd)) HpSleep(1);
while (!IsNewMessage(filter, hWnd))
{
std::this_thread::sleep_for(std::chrono::milliseconds(1));
}

ExMessage msg = GetNextMessage(filter, hWnd);
RemoveMessage(hWnd);
return msg;
Expand Down Expand Up @@ -1706,7 +1712,7 @@ namespace HiEasyX
TranslateMessage(&Msg);
DispatchMessage(&Msg);
}
}
}

HWND initgraph_win32(int w, int h, int flag, LPCTSTR lpszWndTitle, WNDPROC WindowProcess, HWND hParent)
{
Expand Down Expand Up @@ -2072,4 +2078,4 @@ namespace HiEasyX
{
flushmessage_win32(filter, g_vecWindows[m_nWindowIndex].hWnd);
}
}
}
4 changes: 4 additions & 0 deletions 智绘教/IdtConfiguration.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ struct SetListStruct
IntelligentDrawing = true, SmoothWriting = true;

SetSkinMode = 0, SkinMode = 1;

UpdateChannel = "LTS";
}

int StartUp; bool CreateLnk;
Expand All @@ -21,5 +23,7 @@ struct SetListStruct
bool IntelligentDrawing, SmoothWriting;

int SetSkinMode, SkinMode;

string UpdateChannel;
};
extern SetListStruct setlist;
11 changes: 8 additions & 3 deletions 智绘教/IdtDrawpad.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@
#include "IdtTime.h"
#include "IdtUpdate.h"
#include "IdtWindow.h"
//#include <ink_stroke_modeler/stroke_modeler.h>

// ʵʱƽ������
#pragma comment(lib, "absl/AbslWin32MT.lib")

bool main_open;
bool FirstDraw = true;
Expand Down Expand Up @@ -1574,7 +1576,7 @@ void DrawpadDrawing()
ulwi.hdcSrc = GetImageHDC(&window_background);
if (!UpdateLayeredWindowIndirect(drawpad_window, &ulwi))
{
MessageBox(floating_window, L"�ǻ�̻�����ʾ�������⣬���ȷ���������ǻ��\n�˷������ܽ��������", L"�ǻ�̾���", MB_OK);
MessageBox(floating_window, L"�ǻ�̻�����ʾ�������⣬���ȷ���������ǻ��\n�˷������ܽ��������", L"�ǻ�̾���", MB_OK | MB_SYSTEMMODAL);

{
sswindows.clear();
Expand All @@ -1584,6 +1586,7 @@ void DrawpadDrawing()
writejson.imbue(locale("zh_CN.UTF8"));
writejson.open(wstring_to_string(string_to_wstring(global_path) + L"bug fix 240408.01.log").c_str());

writejson << "UpdateLayeredWindowIndirect Error" << GetLastError() << endl;
for (int i = 0; i < (int)sswindows.size(); i++)
{
writejson << to_string(i) << " " + wstring_to_string(sswindows[i]) << endl;
Expand All @@ -1593,6 +1596,8 @@ void DrawpadDrawing()
}

off_signal = 2;

break;
}

tRecord = clock();
Expand All @@ -1608,7 +1613,7 @@ int drawpad_main()

//���ʳ�ʼ��
{
brush.width = 4;
brush.width = 3;
brush.color = brush.primary_colour = RGBA(50, 30, 181, 255);
}
//���ڳ�ʼ��
Expand Down
1 change: 1 addition & 0 deletions 智绘教/IdtDrawpad.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ LRESULT CALLBACK DrawpadHookCallback(int nCode, WPARAM wParam, LPARAM lParam);
void DrawpadInstallHook();

double EuclideanDistance(POINT a, POINT b);
//double EuclideanDistance(PointF a, PointF b);

void MultiFingerDrawing(LONG pid, POINT pt);
void DrawpadDrawing();
Expand Down
Loading
0