Ignore:
Timestamp:
Feb 11, 2010, 11:19:06 PM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.6.1 sources.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/gui/accessible/qaccessible_mac.mm

    r2 r561  
    22**
    33** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
    4 ** Contact: Qt Software Information (qt-info@nokia.com)
     4** All rights reserved.
     5** Contact: Nokia Corporation (qt-info@nokia.com)
    56**
    67** This file is part of the QtGui module of the Qt Toolkit.
     
    2122** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
    2223**
    23 ** In addition, as a special exception, Nokia gives you certain
    24 ** additional rights. These rights are described in the Nokia Qt LGPL
    25 ** Exception version 1.0, included in the file LGPL_EXCEPTION.txt in this
    26 ** package.
     24** In addition, as a special exception, Nokia gives you certain additional
     25** rights.  These rights are described in the Nokia Qt LGPL Exception
     26** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
    2727**
    2828** GNU General Public License Usage
     
    3434** met: http://www.gnu.org/copyleft/gpl.html.
    3535**
    36 ** If you are unsure which license is appropriate for your use, please
    37 ** contact the sales department at qt-sales@nokia.com.
     36** If you have questions regarding the use of this file, please contact
     37** Nokia at qt-info@nokia.com.
    3838** $QT_END_LICENSE$
    3939**
     
    505505
    506506QAElement::QAElement(HIObjectRef object, int child)
    507     :elementRef(
    508 #ifndef QT_MAC_USE_COCOA
    509                 AXUIElementCreateWithHIObjectAndIdentifier(object, child)
    510 #endif
    511 )
    512507{
    513508#ifndef QT_MAC_USE_COCOA
     
    12331228    else if (CFStringCompare(attribute, CFStringRef(QAXHelpAttribute), 0) == kCFCompareEqualTo)
    12341229        return QAccessible::Help;
    1235 #if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
    12361230    else if (CFStringCompare(attribute, CFStringRef(QAXDescriptionAttribute), 0) == kCFCompareEqualTo)
    12371231        return QAccessible::Description;
    1238 #endif
    12391232    else
    12401233        return -1;
     
    14431436    qt_mac_append_cf_uniq(attrs, CFStringRef(QAXEnabledAttribute));
    14441437    qt_mac_append_cf_uniq(attrs, CFStringRef(QAXWindowAttribute));
    1445 #if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
    14461438    qt_mac_append_cf_uniq(attrs, CFStringRef(QAXTopLevelUIElementAttribute));
    1447 #endif
    14481439
    14491440    // Append these names if the QInterafceItem returns any data for them.
    14501441    appendIfSupported(attrs, CFStringRef(QAXTitleAttribute), interface);
    14511442    appendIfSupported(attrs, CFStringRef(QAXValueAttribute), interface);
    1452 #if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
    14531443    appendIfSupported(attrs, CFStringRef(QAXDescriptionAttribute), interface);
    14541444    appendIfSupported(attrs, CFStringRef(QAXLinkedUIElementsAttribute), interface);
    1455 #endif
    14561445    appendIfSupported(attrs, CFStringRef(QAXHelpAttribute), interface);
    14571446    appendIfSupported(attrs, CFStringRef(QAXTitleUIElementAttribute), interface);
     
    17061695    has the Window role. (Can also be a sheet or a drawer)
    17071696*/
    1708 #if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
    17091697static OSStatus handleTopLevelUIElementAttribute(EventHandlerCallRef next_ref, EventRef event, const QAInterface &interface)
    17101698{
    17111699    return navigateAncestors<IsWindowTest>(next_ref, event, interface, CFStringRef(QAXTopLevelUIElementAttribute));
    17121700}
    1713 #endif
    17141701
    17151702/*
     
    18891876    if (CFStringCompare(var, CFStringRef(QAXChildrenAttribute), 0) == kCFCompareEqualTo) {
    18901877        return handleChildrenAttribute(next_ref, event, interface);
    1891 #if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
    18921878    } else if(CFStringCompare(var, CFStringRef(QAXTopLevelUIElementAttribute), 0) == kCFCompareEqualTo) {
    18931879        return handleTopLevelUIElementAttribute(next_ref, event, interface);
    1894 #endif
    18951880    } else if(CFStringCompare(var, CFStringRef(QAXWindowAttribute), 0) == kCFCompareEqualTo) {
    18961881        return handleWindowAttribute(next_ref, event, interface);
     
    19821967        return handleSubroleAttribute(next_ref, event, interface);
    19831968    } else if (CFStringCompare(var, CFStringRef(QAXRoleDescriptionAttribute), 0) == kCFCompareEqualTo) {
    1984 #if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4) && !defined(QT_MAC_USE_COCOA)
     1969#if !defined(QT_MAC_USE_COCOA)
    19851970        if (HICopyAccessibilityRoleDescription) {
    19861971            const CFStringRef roleDescription = HICopyAccessibilityRoleDescription(macRole(interface), 0);
     
    20061991            handleStringAttribute(event, text, interface);
    20071992        }
    2008 #if (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
    20091993    } else if (CFStringCompare(var, CFStringRef(QAXDescriptionAttribute), 0) == kCFCompareEqualTo) {
    20101994        const QAccessible::Role role = interface.role();
     
    20131997    } else if (CFStringCompare(var, CFStringRef(QAXLinkedUIElementsAttribute), 0) == kCFCompareEqualTo) {
    20141998        return CallNextEventHandler(next_ref, event);
    2015 #endif
    20161999    } else if (CFStringCompare(var, CFStringRef(QAXHelpAttribute), 0) == kCFCompareEqualTo) {
    20172000        const QAccessible::Role role = interface.role();
Note: See TracChangeset for help on using the changeset viewer.