Explore Enterprise Education Gitee Premium Gitee AI AI teammates
Fetch the repository succeeded.
Donate
Please sign in before you donate.
Scan WeChat QR to Pay
Cancel
Complete
Prompt
Switch to Alipay.
OK
Cancel
1 Star 0 Fork 4

AlongsCode/eapi

forked from 精易科技/eapi
Create your Gitee Account
Explore and code with more than 14 million developers,Free private repositories !:)
Sign up
Already have an account? Sign in
文件
master
Branches (1)
master
This repository doesn't specify license. Please pay attention to the specific project description and its upstream code dependency when using it.
The license selected for the repository is subject to the license used by the main branch of the repository.
master
Branches (1)
master
Clone or Download
Clone/Download
Prompt
To download the code, please copy the following command and execute it in the terminal
To ensure that your submitted code identity is correctly recognized by Gitee, please execute the following command.
When using the SSH protocol for the first time to clone or push code, follow the prompts below to complete the SSH configuration.
1 Generate RSA keys.
2 Obtain the content of the RSA public key and configure it in SSH Public Keys
To use SVN on Gitee, please visit the usage guide
When using the HTTPS protocol, the command line will prompt for account and password verification as follows. For security reasons, Gitee recommends configure and use personal access tokens instead of login passwords for cloning, pushing, and other operations.
Username for 'https://gitee.com': userName
Password for 'https://userName@gitee.com': # Private Token
master
Branches (1)
master
eapi
/
cppCode
/
eapi_66_SetDiaphaneity.cpp
eapi
/
cppCode
/
eapi_66_SetDiaphaneity.cpp
eapi_66_SetDiaphaneity.cpp 2.03 KB
Copy Edit Raw Blame History
AlongsCode authored 2023年02月09日 00:42 +08:00 . 部分重构
#include "..\include_eapi_header.h"
inline bool SetDiaphaneity(HWND hWnd, unsigned char alpha, COLORREF key, bool through)
{
DWORD dwFlag = LWA_COLORKEY;
LONG TempStyle = GetWindowLongA(hWnd, GWL_EXSTYLE);
if (through) {
SetWindowLongA(hWnd, GWL_EXSTYLE, TempStyle | WS_EX_TRANSPARENT | WS_EX_LAYERED); // 设置鼠标穿透;
}
else {
SetWindowLongA(hWnd, GWL_EXSTYLE, TempStyle | WS_EX_LAYERED);
}
//窗口不完全透明,设置透明读
if (alpha != 0) {
dwFlag |= LWA_ALPHA;
}
return SetLayeredWindowAttributes(hWnd, key, alpha, dwFlag);
}
inline bool SetDiaphaneity(HWND hWnd, unsigned char alpha, bool through)
{
DWORD dwFlag = LWA_ALPHA;
LONG TempStyle = GetWindowLongA(hWnd, GWL_EXSTYLE);
if (through) {
SetWindowLongA(hWnd, GWL_EXSTYLE, TempStyle | WS_EX_TRANSPARENT | WS_EX_LAYERED); // 设置鼠标穿透;
}
else {
SetWindowLongA(hWnd, GWL_EXSTYLE, TempStyle | WS_EX_LAYERED);
}
return SetLayeredWindowAttributes(hWnd, 0, alpha, dwFlag);
}
// 调用格式: SDT_BOOL 设置窗口透明度, 命令说明: "成功返回真;失败返回假。"
// 参数<1>: 窗口句柄 SDT_INT, 参数说明: "要设置透明度的窗口句柄。"
// 参数<2>: [透明度 SDT_INT], 参数说明: "墙纸样式,可以为以下常量值之一:0、#接口常量.居中;1、#接口常量.平铺;2、#接口常量.拉伸。。"
// 参数<3>: [透明色 SDT_INT], 参数说明: "(#颜色)指定某颜色为完全透明(完全透明处不属于该窗口) 可空为不指定."
// 参数<4>: [鼠标穿透 SDT_BOOL], 参数说明: "设置鼠标穿透,默认为假"
EAPI_EXTERN_C void eapi_SetDiaphaneity_66_eapi(PMDATA_INF pRetData, INT nArgCount, PMDATA_INF pArgInf)
{
int type = 0;
if (!pArgInf[0].m_int)
{
pRetData->m_bool = 0;
return;
}
HWND hWnd = (HWND)pArgInf[0].m_int;
INT alpha = 255, through = 0;
if (pArgInf[1].m_dtDataType && pArgInf[1].m_int >= 0 && pArgInf[1].m_int <= 255)
{
alpha = pArgInf[1].m_int;
}
if (pArgInf[3].m_dtDataType && pArgInf[3].m_bool)
{
through = pArgInf[3].m_bool;
}
if (pArgInf[2].m_dtDataType && pArgInf[2].m_int)
{
pRetData->m_bool = SetDiaphaneity(hWnd, alpha, pArgInf[2].m_int, through);
}
else
{
pRetData->m_bool = SetDiaphaneity(hWnd, alpha, through);
}
}
Loading...
Report
Report success
We will send you the feedback within 2 working days through the letter!
Please fill in the reason for the report carefully. Provide as detailed a description as possible.
Please select a report type
Cancel
Send
误判申诉

此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。

如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。

取消
提交

About

易语言支持库 - 应用接口支持库 欢迎易友fork提交代码完成支持库重构改造。
Cancel

Releases

No release

Contributors

All

Activities

can not load any more
Edit
About
Homepage
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C++
1
https://gitee.com/alongscode/eapi.git
git@gitee.com:alongscode/eapi.git
alongscode
eapi
eapi
master
Going to Help Center

Search

Comment
Repository Report
Back to the top
Login prompt
This operation requires login to the code cloud account. Please log in before operating.
Go to login
No account. Register

AltStyle によって変換されたページ (->オリジナル) /