Ignore:
Timestamp:
Dec 21, 2012, 10:37:13 AM (13 years ago)
Author:
dmik
Message:

trunk: Merged in openjdk6 b27 from branches/vendor/oracle.

Location:
trunk/openjdk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/openjdk

  • trunk/openjdk/jdk/src/windows/classes/java/io/Win32FileSystem.java

    r278 r406  
    11/*
    2  * Copyright (c) 1998, 2005, Oracle and/or its affiliates. All rights reserved.
     2 * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved.
    33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    44 *
     
    511511    /* -- File operations -- */
    512512
    513     public native boolean createFileExclusively(String path)
     513    public native boolean createFileExclusively(String path, boolean restrictive)
    514514        throws IOException;
    515515    public boolean delete(File f) {
  • trunk/openjdk/jdk/src/windows/classes/java/io/WinNTFileSystem.java

    r278 r406  
    11/*
    2  * Copyright (c) 2001, 2006, Oracle and/or its affiliates. All rights reserved.
     2 * Copyright (c) 2001, 2012, Oracle and/or its affiliates. All rights reserved.
    33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    44 *
     
    6262    /* -- File operations -- */
    6363
    64     public native boolean createFileExclusively(String path)
     64    public native boolean createFileExclusively(String path, boolean restrictive)
    6565                                               throws IOException;
    6666    protected native boolean delete0(File f);
  • trunk/openjdk/jdk/src/windows/classes/sun/awt/windows/WPopupMenuPeer.java

    r278 r406  
    2727import java.awt.*;
    2828import java.awt.peer.*;
    29 import java.lang.reflect.Field;
    3029
    31 import sun.awt.SunToolkit;
     30import sun.awt.AWTAccessor;
    3231
    3332public class WPopupMenuPeer extends WMenuPeer implements PopupMenuPeer {
     
    3534    // because this method should return null for the TrayIcon
    3635    // popup regardless of that whether it has parent or not.
    37     private static Field f_parent;
    38     private static Field f_isTrayIconPopup;
    39 
    40     static {
    41         f_parent = SunToolkit.getField(MenuComponent.class, "parent");
    42         f_isTrayIconPopup = SunToolkit.getField(PopupMenu.class, "isTrayIconPopup");
    43     }
    4436
    4537    public WPopupMenuPeer(PopupMenu target) {
     
    4739        MenuContainer parent = null;
    4840        boolean isTrayIconPopup = false;
    49         try {
    50             isTrayIconPopup = ((Boolean)f_isTrayIconPopup.get(target)).booleanValue();
    51             if (isTrayIconPopup) {
    52                 parent = (MenuContainer)f_parent.get(target);
    53             } else {
    54                 parent = target.getParent();
    55             }
    56         } catch (IllegalAccessException iae) {
    57             iae.printStackTrace();
    58             return;
     41        isTrayIconPopup = AWTAccessor.getPopupMenuAccessor().isTrayIconPopup(target);
     42        if (isTrayIconPopup) {
     43            parent = AWTAccessor.getMenuComponentAccessor().getParent(target);
     44        } else {
     45            parent = target.getParent();
    5946        }
    6047
Note: See TracChangeset for help on using the changeset viewer.