Skip to content

Commit

Permalink
Merge branch 'JENKINS-25358' of github.com:rodrigc/jenkins
Browse files Browse the repository at this point in the history
  • Loading branch information
jglick committed Oct 30, 2014
2 parents 47b8d96 + c577fff commit e22cb19
Showing 1 changed file with 26 additions and 3 deletions.
29 changes: 26 additions & 3 deletions core/src/main/java/hudson/util/jna/SHELLEXECUTEINFO.java
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@

import com.sun.jna.Pointer;
import com.sun.jna.Structure;
import com.sun.jna.Union;
import java.util.Arrays;
import java.util.List;

Expand Down Expand Up @@ -69,7 +70,7 @@ public class SHELLEXECUTEINFO extends Structure {
public String lpClass;
public Pointer hkeyClass;
public int dwHotKey;
public Pointer hIcon;
public DUMMYUNIONNAME_union DUMMYUNIONNAME;
public Pointer hProcess;

public static final int SEE_MASK_NOCLOSEPROCESS = 0x40;
Expand All @@ -80,7 +81,29 @@ public class SHELLEXECUTEINFO extends Structure {
protected List getFieldOrder() {
return Arrays.asList("cbSize", "fMask", "hwnd", "lpVerb",
"lpFile", "lpParameters", "lpDirectory", "nShow", "hInstApp",
"lpIDList", "lpClass", "hkeyClass", "dwHotKey", "hIcon",
"hProcess", "SEE_MASK_NOCLOSEPROCESS", "SW_HIDE", "SW_SHOW");
"lpIDList", "lpClass", "hkeyClass", "dwHotKey", "DUMMYUNIONNAME",
"hProcess");
}

public static class DUMMYUNIONNAME_union extends Union {
public Pointer hIcon;
public Pointer hMonitor;

public DUMMYUNIONNAME_union() {
super();
}

public DUMMYUNIONNAME_union(Pointer hIcon_or_hMonitor) {
super();
this.hMonitor = this.hIcon = hIcon_or_hMonitor;
setType(Pointer.class);
}

public static class ByReference extends DUMMYUNIONNAME_union implements Structure.ByReference {

};
public static class ByValue extends DUMMYUNIONNAME_union implements Structure.ByValue {

};
};
}

0 comments on commit e22cb19

Please sign in to comment.