mirror of
https://github.com/greenshot/greenshot
synced 2025-08-19 13:10:00 -07:00
Fix for generating the list of windows which can be selected.
Fix for including the credentials of the web services in azure-pipelines.yml
This commit is contained in:
parent
77c1b3d2c5
commit
043b6048ae
2 changed files with 23 additions and 6 deletions
|
@ -548,13 +548,21 @@ namespace GreenshotPlugin.Core
|
||||||
User32.ShowWindow(Handle, ShowWindowCommand.Hide);
|
User32.ShowWindow(Handle, ShowWindowCommand.Hide);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Returns if this window is cloaked
|
||||||
|
/// </summary>
|
||||||
|
public bool IsCloaked
|
||||||
|
{
|
||||||
|
get => DWM.IsWindowCloaked(Handle);
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets whether the window is visible.
|
/// Gets whether the window is visible.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public bool Visible {
|
public bool Visible {
|
||||||
get {
|
get {
|
||||||
// Tip from Raymond Chen
|
// Tip from Raymond Chen
|
||||||
if (DWM.IsWindowCloaked(Handle))
|
if (IsCloaked)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -1525,6 +1533,12 @@ namespace GreenshotPlugin.Core
|
||||||
/// <returns>bool</returns>
|
/// <returns>bool</returns>
|
||||||
private static bool IsTopLevel(WindowDetails window)
|
private static bool IsTopLevel(WindowDetails window)
|
||||||
{
|
{
|
||||||
|
// Window is not on this desktop
|
||||||
|
if (window.IsCloaked)
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
// Ignore windows without title
|
// Ignore windows without title
|
||||||
if (window.Text.Length == 0)
|
if (window.Text.Length == 0)
|
||||||
{
|
{
|
||||||
|
@ -1535,7 +1549,7 @@ namespace GreenshotPlugin.Core
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
// Windows without size
|
// Windows without size
|
||||||
if (window.WindowRectangle.Size.IsEmpty)
|
if (window.WindowRectangle.Size.Width * window.WindowRectangle.Size.Height == 0)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,10 +19,13 @@ stages:
|
||||||
vmImage: 'Windows-latest'
|
vmImage: 'Windows-latest'
|
||||||
|
|
||||||
variables:
|
variables:
|
||||||
solution: 'Greenshot.sln'
|
- group: 'Plug-in Credentials'
|
||||||
buildPlatform: 'Any CPU'
|
- name: solution
|
||||||
buildConfiguration: 'Release'
|
value: 'Greenshot.sln'
|
||||||
group: 'Plug-in Credentials'
|
- name: buildPlatform
|
||||||
|
value: 'Any CPU'
|
||||||
|
- name: buildConfiguration
|
||||||
|
value: 'Release'
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- task: NuGetToolInstaller@1
|
- task: NuGetToolInstaller@1
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue