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:
10 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
  • trunk/openjdk/jdk/src/windows/native/java/io/Win32FileSystem_md.c

    r330 r406  
    11/*
    2  * Copyright (c) 1998, 2006, 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 *
     
    274274JNIEXPORT jboolean JNICALL
    275275Java_java_io_Win32FileSystem_createFileExclusively(JNIEnv *env, jclass cls,
    276                                                    jstring pathname)
     276                                                   jstring pathname,
     277                                                   jboolean restrictive)
    277278{
    278279    jboolean rv = JNI_FALSE;
  • trunk/openjdk/jdk/src/windows/native/java/io/WinNTFileSystem_md.c

    r330 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 *
     
    366366JNIEXPORT jboolean JNICALL
    367367Java_java_io_WinNTFileSystem_createFileExclusively(JNIEnv *env, jclass cls,
    368                                                    jstring path)
     368                                                   jstring path,
     369                                                   jboolean restrictive)
    369370{
    370371    HANDLE h = NULL;
  • trunk/openjdk/jdk/src/windows/native/java/net/net_util_md.c

    r333 r406  
    11/*
    2  * Copyright (c) 1997, 2007, Oracle and/or its affiliates. All rights reserved.
     2 * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
    33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    44 *
     
    133133
    134134void initLocalAddrTable () {}
     135void parseExclusiveBindProperty (JNIEnv *env) {}
    135136
    136137/*
  • trunk/openjdk/jdk/src/windows/native/sun/windows/awt_Dialog.cpp

    r309 r406  
    429429    JNIEnv *env = (JNIEnv *)JNU_GetEnv(jvm, JNI_VERSION_1_2);
    430430
    431     jlongArray windows = (jlongArray)(env->CallStaticObjectMethod(AwtWindow::wwindowPeerCls,
    432                                                                   AwtWindow::getActiveWindowsMID));
     431    jclass wwindowPeerCls = env->FindClass("sun/awt/windows/WWindowPeer");
     432    jmethodID getActiveWindowsMID = env->GetStaticMethodID(wwindowPeerCls,
     433                                                           "getActiveWindowHandles", "()[J");
     434    DASSERT(getActiveWindowsMID != NULL);
     435    jlongArray windows = (jlongArray)(env->CallStaticObjectMethod(wwindowPeerCls,
     436                                                                  getActiveWindowsMID));
    433437    if (windows == NULL) {
    434438        return;
  • trunk/openjdk/jdk/src/windows/native/sun/windows/awt_Window.cpp

    r309 r406  
    11/*
    2  * Copyright (c) 1996, 2007, Oracle and/or its affiliates. All rights reserved.
     2 * Copyright (c) 1996, 2012, Oracle and/or its affiliates. All rights reserved.
    33 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
    44 *
     
    125125jfieldID AwtWindow::locationByPlatformID;
    126126jfieldID AwtWindow::autoRequestFocusID;
    127 
    128 jclass AwtWindow::wwindowPeerCls;
    129 jmethodID AwtWindow::getActiveWindowsMID;
    130127
    131128jfieldID AwtWindow::sysXID;
     
    21692166    AwtWindow::sysHID = env->GetFieldID(cls, "sysH", "I");
    21702167
    2171     AwtWindow::wwindowPeerCls = cls;
    2172     AwtWindow::getActiveWindowsMID =
    2173         env->GetStaticMethodID(cls, "getActiveWindowHandles", "()[J");
    2174     DASSERT(AwtWindow::getActiveWindowsMID != NULL);
    2175 
    21762168    CATCH_BAD_ALLOC;
    21772169}
  • trunk/openjdk/jdk/src/windows/native/sun/windows/awt_Window.h

    r309 r406  
    5757    static jfieldID screenID; /* screen number passed over from WindowPeer */
    5858    static jfieldID autoRequestFocusID;
    59 
    60     /* WWindowPeer class */
    61     static jclass wwindowPeerCls;
    62     /* long[] getActiveWindowHandles() method in WWindowPeer */
    63     static jmethodID getActiveWindowsMID;
    6459
    6560    // The coordinates at the peer.
Note: See TracChangeset for help on using the changeset viewer.