< prev index next >
src/java.desktop/windows/native/libawt/windows/awt_PrintControl.cpp
Print this page
@@ -796,11 +796,14 @@
pd.Flags |= PD_PRINTTOFILE;
}
// selectType identifies whether No selection (2D) or
// SunPageSelection (AWT)
- if (selectType != 0) {
+ // If getSelectAttrib() returns PD_NOSELECTION, then
+ // do not select Selection button but also do not set
+ // PD_NOSELECTION flag as it disables selection button
+ if (selectType != 0 && selectType != PD_NOSELECTION) {
pd.Flags |= selectType;
}
if (!env->CallBooleanMethod(printCtrl,
AwtPrintControl::getPrintToFileEnabledID)) {
< prev index next >