LCOV - code coverage report
Current view: directory - accessible/src/xul - nsXULTabAccessible.h (source / functions) Found Hit Coverage
Test: app.info Lines: 4 0 0.0 %
Date: 2012-06-02 Functions: 8 0 0.0 %

       1                 : /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
       2                 : /* ***** BEGIN LICENSE BLOCK *****
       3                 :  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
       4                 :  *
       5                 :  * The contents of this file are subject to the Mozilla Public License Version
       6                 :  * 1.1 (the "License"); you may not use this file except in compliance with
       7                 :  * the License. You may obtain a copy of the License at
       8                 :  * http://www.mozilla.org/MPL/
       9                 :  *
      10                 :  * Software distributed under the License is distributed on an "AS IS" basis,
      11                 :  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
      12                 :  * for the specific language governing rights and limitations under the
      13                 :  * License.
      14                 :  *
      15                 :  * The Original Code is mozilla.org code.
      16                 :  *
      17                 :  * The Initial Developer of the Original Code is
      18                 :  * Netscape Communications Corporation.
      19                 :  * Portions created by the Initial Developer are Copyright (C) 1998
      20                 :  * the Initial Developer. All Rights Reserved.
      21                 :  *
      22                 :  * Contributor(s):
      23                 :  *   Author: John Gaunt (jgaunt@netscape.com)
      24                 :  *
      25                 :  * Alternatively, the contents of this file may be used under the terms of
      26                 :  * either of the GNU General Public License Version 2 or later (the "GPL"),
      27                 :  * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
      28                 :  * in which case the provisions of the GPL or the LGPL are applicable instead
      29                 :  * of those above. If you wish to allow use of your version of this file only
      30                 :  * under the terms of either the GPL or the LGPL, and not to allow others to
      31                 :  * use your version of this file under the terms of the MPL, indicate your
      32                 :  * decision by deleting the provisions above and replace them with the notice
      33                 :  * and other provisions required by the GPL or the LGPL. If you do not delete
      34                 :  * the provisions above, a recipient may use your version of this file under
      35                 :  * the terms of any one of the MPL, the GPL or the LGPL.
      36                 :  *
      37                 :  * ***** END LICENSE BLOCK ***** */
      38                 : 
      39                 : #ifndef _nsXULTabAccessible_H_
      40                 : #define _nsXULTabAccessible_H_
      41                 : 
      42                 : // NOTE: alphabetically ordered
      43                 : #include "nsBaseWidgetAccessible.h"
      44                 : #include "nsXULMenuAccessible.h"
      45                 : #include "XULSelectControlAccessible.h"
      46                 : 
      47                 : /**
      48                 :  * An individual tab, xul:tab element.
      49                 :  */
      50                 : class nsXULTabAccessible : public nsAccessibleWrap
      51               0 : {
      52                 : public:
      53                 :   enum { eAction_Switch = 0 };
      54                 : 
      55                 :   nsXULTabAccessible(nsIContent* aContent, nsDocAccessible* aDoc);
      56                 : 
      57                 :   // nsIAccessible
      58                 :   NS_IMETHOD GetActionName(PRUint8 aIndex, nsAString& aName);
      59                 :   NS_IMETHOD DoAction(PRUint8 index);
      60                 : 
      61                 :   // nsAccessible
      62                 :   virtual void GetPositionAndSizeInternal(PRInt32 *aPosInSet,
      63                 :                                           PRInt32 *aSetSize);
      64                 :   virtual mozilla::a11y::role NativeRole();
      65                 :   virtual PRUint64 NativeState();
      66                 :   virtual Relation RelationByType(PRUint32 aType);
      67                 : 
      68                 :   // ActionAccessible
      69                 :   virtual PRUint8 ActionCount();
      70                 : };
      71                 : 
      72                 : 
      73                 : /**
      74                 :  * A container of tab objects, xul:tabs element.
      75                 :  */
      76                 : class nsXULTabsAccessible : public XULSelectControlAccessible
      77               0 : {
      78                 : public:
      79                 :   nsXULTabsAccessible(nsIContent* aContent, nsDocAccessible* aDoc);
      80                 : 
      81                 :   // nsIAccessible
      82                 :   NS_IMETHOD GetValue(nsAString& _retval);
      83                 : 
      84                 :   // nsAccessible
      85                 :   virtual nsresult GetNameInternal(nsAString& aName);
      86                 :   virtual mozilla::a11y::role NativeRole();
      87                 : 
      88                 :   // ActionAccessible
      89                 :   virtual PRUint8 ActionCount();
      90                 : };
      91                 : 
      92                 : 
      93                 : /** 
      94                 :  * A container of tab panels, xul:tabpanels element.
      95                 :  */
      96                 : class nsXULTabpanelsAccessible : public nsAccessibleWrap
      97               0 : {
      98                 : public:
      99                 :   nsXULTabpanelsAccessible(nsIContent* aContent, nsDocAccessible* aDoc);
     100                 : 
     101                 :   // nsAccessible
     102                 :   virtual mozilla::a11y::role NativeRole();
     103                 : };
     104                 : 
     105                 : 
     106                 : /**
     107                 :  * A tabpanel object, child elements of xul:tabpanels element. Note,the object
     108                 :  * is created from nsAccessibilityService::GetAccessibleForDeckChildren()
     109                 :  * method and we do not use nsIAccessibleProvider interface here because
     110                 :  * all children of xul:tabpanels element acts as xul:tabpanel element.
     111                 :  *
     112                 :  * XXX: we need to move the class logic into generic class since
     113                 :  * for example we do not create instance of this class for XUL textbox used as
     114                 :  * a tabpanel.
     115                 :  */
     116                 : class nsXULTabpanelAccessible : public nsAccessibleWrap
     117               0 : {
     118                 : public:
     119                 :   nsXULTabpanelAccessible(nsIContent* aContent, nsDocAccessible* aDoc);
     120                 : 
     121                 :   // nsAccessible
     122                 :   virtual mozilla::a11y::role NativeRole();
     123                 :   virtual Relation RelationByType(PRUint32 aType);
     124                 : };
     125                 : 
     126                 : #endif
     127                 : 

Generated by: LCOV version 1.7