1*cdf0e10cSrcweir/************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4*cdf0e10cSrcweir * 5*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 6*cdf0e10cSrcweir * 7*cdf0e10cSrcweir * OpenOffice.org - a multi-platform office productivity suite 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * This file is part of OpenOffice.org. 10*cdf0e10cSrcweir * 11*cdf0e10cSrcweir * OpenOffice.org is free software: you can redistribute it and/or modify 12*cdf0e10cSrcweir * it under the terms of the GNU Lesser General Public License version 3 13*cdf0e10cSrcweir * only, as published by the Free Software Foundation. 14*cdf0e10cSrcweir * 15*cdf0e10cSrcweir * OpenOffice.org is distributed in the hope that it will be useful, 16*cdf0e10cSrcweir * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*cdf0e10cSrcweir * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*cdf0e10cSrcweir * GNU Lesser General Public License version 3 for more details 19*cdf0e10cSrcweir * (a copy is included in the LICENSE file that accompanied this code). 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * You should have received a copy of the GNU Lesser General Public License 22*cdf0e10cSrcweir * version 3 along with OpenOffice.org. If not, see 23*cdf0e10cSrcweir * <http://www.openoffice.org/license.html> 24*cdf0e10cSrcweir * for a copy of the LGPLv3 License. 25*cdf0e10cSrcweir * 26*cdf0e10cSrcweir ************************************************************************/ 27*cdf0e10cSrcweir 28*cdf0e10cSrcweir#ifndef __com_sun_star_accessibility_XAccessibleKeyBinding_idl__ 29*cdf0e10cSrcweir#define __com_sun_star_accessibility_XAccessibleKeyBinding_idl__ 30*cdf0e10cSrcweir 31*cdf0e10cSrcweir#ifndef __com_sun_star_uno_XInterface_idl__ 32*cdf0e10cSrcweir#include <com/sun/star/uno/XInterface.idl> 33*cdf0e10cSrcweir#endif 34*cdf0e10cSrcweir#ifndef __com_sun_star_awt_KeyStroke_idl__ 35*cdf0e10cSrcweir#include <com/sun/star/awt/KeyStroke.idl> 36*cdf0e10cSrcweir#endif 37*cdf0e10cSrcweir#ifndef __com_sun_star_lang_IndexOutOfBoundsException_idl__ 38*cdf0e10cSrcweir#include <com/sun/star/lang/IndexOutOfBoundsException.idl> 39*cdf0e10cSrcweir#endif 40*cdf0e10cSrcweir 41*cdf0e10cSrcweirmodule com { module sun { module star { module accessibility { 42*cdf0e10cSrcweir 43*cdf0e10cSrcweir/** This interface can be used to represent any number of key bindings which 44*cdf0e10cSrcweir then can be associated to a certain action. 45*cdf0e10cSrcweir 46*cdf0e10cSrcweir <p>There can be zero, one, or more key bindings. Each key binding consists 47*cdf0e10cSrcweir of a sequence of <type scope="::com::sun::star::awt">KeyStroke</type> 48*cdf0e10cSrcweir objects. The association of an action with a key binding is established 49*cdf0e10cSrcweir by the <type>XAccessibleAction</type> interface returning an 50*cdf0e10cSrcweir <type>XAccessibleKeyBinding</type> object.</p> 51*cdf0e10cSrcweir 52*cdf0e10cSrcweir <p>A key binding describes alternative ways how to invoke an action with 53*cdf0e10cSrcweir pressing one or more keys after each other. Each individual sequence of 54*cdf0e10cSrcweir key strokes </p> 55*cdf0e10cSrcweir 56*cdf0e10cSrcweir @since OOo 1.1.2 57*cdf0e10cSrcweir*/ 58*cdf0e10cSrcweirpublished interface XAccessibleKeyBinding : ::com::sun::star::uno::XInterface 59*cdf0e10cSrcweir{ 60*cdf0e10cSrcweir /** Return the number of available key bindings. 61*cdf0e10cSrcweir @return 62*cdf0e10cSrcweir The returned value may be 0 to indicate that there are no key 63*cdf0e10cSrcweir bindings or the positive number of the available key bindings. 64*cdf0e10cSrcweir */ 65*cdf0e10cSrcweir long getAccessibleKeyBindingCount (); 66*cdf0e10cSrcweir 67*cdf0e10cSrcweir /** The returned sequence of key strokes describes one method to invoke 68*cdf0e10cSrcweir the associated action (the one from which you obtained the object at 69*cdf0e10cSrcweir which you called this method) by pressing keys. The keys specified 70*cdf0e10cSrcweir by each of the returned key strokes have to be pressed at the same 71*cdf0e10cSrcweir time (the Control-key and the A-key for example). The keys of 72*cdf0e10cSrcweir one key stroke have to be released before pressing those of the 73*cdf0e10cSrcweir next. The order of the key strokes in the sequence define the order 74*cdf0e10cSrcweir in which to press them. 75*cdf0e10cSrcweir @param nIndex 76*cdf0e10cSrcweir The index selects one of alternative key bindings. It has to 77*cdf0e10cSrcweir non-negative and smaller then the number of key bindings as 78*cdf0e10cSrcweir returned by the <member>geetAccessibleKeyBindingCount()</member> 79*cdf0e10cSrcweir method. 80*cdf0e10cSrcweir @return 81*cdf0e10cSrcweir The returned sequence of key strokes specifies one way to invoke 82*cdf0e10cSrcweir the associated action. The sequence may be empty (but should 83*cdf0e10cSrcweir not be; better not to return such a key binding at all). 84*cdf0e10cSrcweir @throws ::com::sun::star::lang::IndexOutOfBoundsException 85*cdf0e10cSrcweir if the index is not valid. 86*cdf0e10cSrcweir */ 87*cdf0e10cSrcweir sequence<::com::sun::star::awt::KeyStroke> getAccessibleKeyBinding ([in] long nIndex) 88*cdf0e10cSrcweir raises (::com::sun::star::lang::IndexOutOfBoundsException); 89*cdf0e10cSrcweir}; 90*cdf0e10cSrcweir 91*cdf0e10cSrcweir}; }; }; }; 92*cdf0e10cSrcweir 93*cdf0e10cSrcweir#endif 94