widget/cocoa/nsBidiKeyboard.mm

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/widget/cocoa/nsBidiKeyboard.mm	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,42 @@
     1.4 +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
     1.5 + *
     1.6 + * This Source Code Form is subject to the terms of the Mozilla Public
     1.7 + * License, v. 2.0. If a copy of the MPL was not distributed with this
     1.8 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     1.9 +
    1.10 +#include "nsBidiKeyboard.h"
    1.11 +#include "nsCocoaUtils.h"
    1.12 +#include "TextInputHandler.h"
    1.13 +
    1.14 +// This must be the last include:
    1.15 +#include "nsObjCExceptions.h"
    1.16 +
    1.17 +using namespace mozilla::widget;
    1.18 +
    1.19 +NS_IMPL_ISUPPORTS(nsBidiKeyboard, nsIBidiKeyboard)
    1.20 +
    1.21 +nsBidiKeyboard::nsBidiKeyboard() : nsIBidiKeyboard()
    1.22 +{
    1.23 +  Reset();
    1.24 +}
    1.25 +
    1.26 +nsBidiKeyboard::~nsBidiKeyboard()
    1.27 +{
    1.28 +}
    1.29 +
    1.30 +NS_IMETHODIMP nsBidiKeyboard::Reset()
    1.31 +{
    1.32 +  return NS_OK;
    1.33 +}
    1.34 +
    1.35 +NS_IMETHODIMP nsBidiKeyboard::IsLangRTL(bool *aIsRTL)
    1.36 +{
    1.37 +  *aIsRTL = TISInputSourceWrapper::CurrentInputSource().IsForRTLLanguage();
    1.38 +  return NS_OK;
    1.39 +}
    1.40 +
    1.41 +NS_IMETHODIMP nsBidiKeyboard::GetHaveBidiKeyboards(bool* aResult)
    1.42 +{
    1.43 +  // not implemented yet
    1.44 +  return NS_ERROR_NOT_IMPLEMENTED;
    1.45 +}

mercurial