This commit is contained in:
Richard Newman 2012-10-06 13:25:29 -07:00
Родитель 19a6691aef 1bcac7940e
Коммит 783bc62129
418 изменённых файлов: 6988 добавлений и 3245 удалений

Просмотреть файл

@ -33,7 +33,10 @@ SHARED_LIBRARY_LIBS = \
$(NULL)
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
SHARED_LIBRARY_LIBS += ../src/windows/uia/$(LIB_PREFIX)accessibility_toolkit_uia_s.$(LIB_SUFFIX)
SHARED_LIBRARY_LIBS += \
../src/windows/ia2/$(LIB_PREFIX)accessibility_toolkit_ia2_s.$(LIB_SUFFIX) \
../src/windows/uia/$(LIB_PREFIX)accessibility_toolkit_uia_s.$(LIB_SUFFIX) \
$(NULL)
endif
ifdef MOZ_XUL

Просмотреть файл

@ -6,6 +6,7 @@
#include "InterfaceInitFuncs.h"
#include "Accessible-inl.h"
#include "AccessibleWrap.h"
#include "nsAccUtils.h"
#include "TableAccessible.h"

Просмотреть файл

@ -695,11 +695,40 @@ logging::AccessibleNNode(const char* aDescr, Accessible* aAccessible)
static_cast<void*>(aAccessible->Document()),
static_cast<void*>(aAccessible->GetDocumentNode()));
printf(" Document");
printf(" Document ");
LogDocURI(static_cast<nsIDocument*>(aAccessible->GetDocumentNode()));
printf("\n");
}
void
logging::AccessibleNNode(const char* aDescr, nsINode* aNode)
{
DocAccessible* document =
GetAccService()->GetDocAccessible(aNode->OwnerDoc());
if (document) {
Accessible* accessible = document->GetAccessible(aNode);
if (accessible) {
AccessibleNNode(aDescr, accessible);
return;
}
}
nsAutoCString nodeDescr("Not accessible ");
nodeDescr.Append(aDescr);
Node(nodeDescr.get(), aNode);
}
void
logging::DOMEvent(const char* aDescr, nsINode* aOrigTarget,
const nsAString& aEventType)
{
logging::MsgBegin("DOMEvents", "event '%s' %s",
NS_ConvertUTF16toUTF8(aEventType).get(), aDescr);
logging::AccessibleNNode("Target", aOrigTarget);
logging::MsgEnd();
}
void
logging::Stack()
{

Просмотреть файл

@ -153,6 +153,13 @@ void Node(const char* aDescr, nsINode* aNode);
* Log the accessible and its DOM node as a message entry.
*/
void AccessibleNNode(const char* aDescr, Accessible* aAccessible);
void AccessibleNNode(const char* aDescr, nsINode* aNode);
/**
* Log the DOM event.
*/
void DOMEvent(const char* aDescr, nsINode* aOrigTarget,
const nsAString& aEventType);
/**
* Log the call stack, two spaces offset is used.

Просмотреть файл

@ -93,6 +93,7 @@ else
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
LOCAL_INCLUDES += \
-I$(srcdir)/../msaa \
-I$(srcdir)/../windows/ia2 \
$(NULL)
else
ifeq ($(MOZ_WIDGET_TOOLKIT),cocoa)

Просмотреть файл

@ -258,22 +258,18 @@ RootAccessible::HandleEvent(nsIDOMEvent* aDOMEvent)
if (!origTargetNode)
return NS_OK;
DocAccessible* document =
GetAccService()->GetDocAccessible(origTargetNode->OwnerDoc());
if (document) {
#ifdef A11Y_LOG
if (logging::IsEnabled(logging::eDOMEvents)) {
nsAutoString eventType;
aDOMEvent->GetType(eventType);
logging::MsgBegin("DOMEvents", "event '%s' handled",
NS_ConvertUTF16toUTF8(eventType).get());
logging::Node("target", origTargetNode);
logging::MsgEnd();
logging::DOMEvent("handled", origTargetNode, eventType);
}
#endif
DocAccessible* document =
GetAccService()->GetDocAccessible(origTargetNode->OwnerDoc());
if (document) {
// Root accessible exists longer than any of its descendant documents so
// that we are guaranteed notification is processed before root accessible
// is destroyed.
@ -296,6 +292,11 @@ RootAccessible::ProcessDOMEvent(nsIDOMEvent* aDOMEvent)
nsAutoString eventType;
aDOMEvent->GetType(eventType);
#ifdef A11Y_LOG
if (logging::IsEnabled(logging::eDOMEvents))
logging::DOMEvent("processed", origTargetNode, eventType);
#endif
if (eventType.EqualsLiteral("popuphiding")) {
HandlePopupHidingEvent(origTargetNode);
return;

Просмотреть файл

@ -484,7 +484,7 @@ HTMLTextFieldAccessible::DoAction(uint8_t aIndex)
if (aIndex == 0) {
nsHTMLInputElement* element = nsHTMLInputElement::FromContent(mContent);
if (element)
return element->Focus();
return element->DOMFocus();
return NS_ERROR_FAILURE;
}

Просмотреть файл

@ -50,6 +50,7 @@ else
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
LOCAL_INCLUDES += \
-I$(srcdir)/../msaa \
-I$(srcdir)/../windows/ia2 \
$(NULL)
else
ifeq ($(MOZ_WIDGET_TOOLKIT),cocoa)

Просмотреть файл

@ -19,7 +19,7 @@ NS_IMPL_ISUPPORTS_INHERITED0(ARIAGridAccessibleWrap,
IMPL_IUNKNOWN_INHERITED1(ARIAGridAccessibleWrap,
AccessibleWrap,
CAccessibleTable)
ia2AccessibleTable)
////////////////////////////////////////////////////////////////////////////////
@ -31,5 +31,5 @@ NS_IMPL_ISUPPORTS_INHERITED0(ARIAGridCellAccessibleWrap,
IMPL_IUNKNOWN_INHERITED1(ARIAGridCellAccessibleWrap,
HyperTextAccessibleWrap,
CAccessibleTableCell)
ia2AccessibleTableCell)

Просмотреть файл

@ -9,8 +9,8 @@
#define MOZILLA_A11Y_ARIAGRIDACCESSIBLEWRAP_H
#include "ARIAGridAccessible.h"
#include "CAccessibleTable.h"
#include "CAccessibleTableCell.h"
#include "ia2AccessibleTable.h"
#include "ia2AccessibleTableCell.h"
namespace mozilla {
namespace a11y {
@ -20,7 +20,7 @@ namespace a11y {
* IAccessibleTable2 interfaces.
*/
class ARIAGridAccessibleWrap : public ARIAGridAccessible,
public CAccessibleTable
public ia2AccessibleTable
{
public:
ARIAGridAccessibleWrap(nsIContent* aContent, DocAccessible* aDoc) :
@ -38,7 +38,7 @@ public:
* IAccessibleTableCell interface.
*/
class ARIAGridCellAccessibleWrap : public ARIAGridCellAccessible,
public CAccessibleTableCell
public ia2AccessibleTableCell
{
public:
ARIAGridCellAccessibleWrap(nsIContent* aContent, DocAccessible* aDoc) :

Просмотреть файл

@ -107,7 +107,7 @@ __try {
}
if (NULL == *ppv) {
HRESULT hr = CAccessibleValue::QueryInterface(iid, ppv);
HRESULT hr = ia2AccessibleValue::QueryInterface(iid, ppv);
if (SUCCEEDED(hr))
return hr;
}

Просмотреть файл

@ -15,7 +15,7 @@
#include "Accessible2.h"
#include "ia2AccessibleComponent.h"
#include "ia2AccessibleHyperlink.h"
#include "CAccessibleValue.h"
#include "ia2AccessibleValue.h"
#define DECL_IUNKNOWN \
public: \
@ -119,7 +119,7 @@ __try { \
class AccessibleWrap : public Accessible,
public ia2AccessibleComponent,
public ia2AccessibleHyperlink,
public CAccessibleValue,
public ia2AccessibleValue,
public IAccessible2
{
public: // construction, destruction

Просмотреть файл

@ -18,7 +18,7 @@ NS_IMPL_ISUPPORTS_INHERITED0(HTMLTableAccessibleWrap,
IMPL_IUNKNOWN_INHERITED1(HTMLTableAccessibleWrap,
AccessibleWrap,
CAccessibleTable)
ia2AccessibleTable)
////////////////////////////////////////////////////////////////////////////////
@ -30,7 +30,7 @@ NS_IMPL_ISUPPORTS_INHERITED0(HTMLTableCellAccessibleWrap,
IMPL_IUNKNOWN_INHERITED1(HTMLTableCellAccessibleWrap,
HyperTextAccessibleWrap,
CAccessibleTableCell)
ia2AccessibleTableCell)
////////////////////////////////////////////////////////////////////////////////
@ -42,4 +42,4 @@ NS_IMPL_ISUPPORTS_INHERITED0(HTMLTableHeaderCellAccessibleWrap,
IMPL_IUNKNOWN_INHERITED1(HTMLTableHeaderCellAccessibleWrap,
HyperTextAccessibleWrap,
CAccessibleTableCell)
ia2AccessibleTableCell)

Просмотреть файл

@ -10,8 +10,8 @@
#include "HTMLTableAccessible.h"
#include "CAccessibleTable.h"
#include "CAccessibleTableCell.h"
#include "ia2AccessibleTable.h"
#include "ia2AccessibleTableCell.h"
namespace mozilla {
namespace a11y {
@ -21,7 +21,7 @@ namespace a11y {
* and IAccessibleTable2 interfaces.
*/
class HTMLTableAccessibleWrap : public HTMLTableAccessible,
public CAccessibleTable
public ia2AccessibleTable
{
public:
HTMLTableAccessibleWrap(nsIContent* aContent, DocAccessible* aDoc) :
@ -40,7 +40,7 @@ public:
* IAccessibleTableCell interface.
*/
class HTMLTableCellAccessibleWrap : public HTMLTableCellAccessible,
public CAccessibleTableCell
public ia2AccessibleTableCell
{
public:
HTMLTableCellAccessibleWrap(nsIContent* aContent, DocAccessible* aDoc) :
@ -59,7 +59,7 @@ public:
* IAccessibleTableCell interface.
*/
class HTMLTableHeaderCellAccessibleWrap : public HTMLTableHeaderCellAccessible,
public CAccessibleTableCell
public ia2AccessibleTableCell
{
public:
HTMLTableHeaderCellAccessibleWrap(nsIContent* aContent,

Просмотреть файл

@ -26,19 +26,8 @@ CPPSRCS = \
nsAccessNodeWrap.cpp \
nsHTMLWin32ObjectAccessible.cpp \
nsWinUtils.cpp \
CAccessibleTable.cpp \
CAccessibleTableCell.cpp \
CAccessibleValue.cpp \
Compatibility.cpp \
EnumVariant.cpp \
ia2AccessibleAction.cpp \
ia2AccessibleComponent.cpp \
ia2AccessibleEditableText.cpp \
ia2AccessibleImage.cpp \
ia2AccessibleHyperlink.cpp \
ia2AccessibleHypertext.cpp \
ia2AccessibleRelation.cpp \
ia2AccessibleText.cpp \
RootAccessibleWrap.cpp \
TextLeafAccessibleWrap.cpp \
$(NULL)
@ -52,13 +41,6 @@ CPPSRCS += \
endif
EXPORTS = \
CAccessibleValue.h \
ia2AccessibleAction.h \
ia2AccessibleComponent.h \
ia2AccessibleEditableText.h \
ia2AccessibleHyperlink.h \
ia2AccessibleHypertext.h \
ia2AccessibleText.h \
nsAccessNodeWrap.h \
$(NULL)
@ -84,6 +66,7 @@ LOCAL_INCLUDES += \
-I$(srcdir)/../html \
-I$(srcdir)/../xpcom \
-I$(srcdir)/../xul \
-I$(srcdir)/../windows/ia2 \
-I$(srcdir)/../windows/uia \
-I$(srcdir)/../../../content/base/src \
-I$(srcdir)/../../../content/events/src \

Просмотреть файл

@ -21,7 +21,7 @@ NS_IMPL_ISUPPORTS_INHERITED0(XULListboxAccessibleWrap,
XULListboxAccessible)
IMPL_IUNKNOWN_QUERY_HEAD(XULListboxAccessibleWrap)
IMPL_IUNKNOWN_QUERY_CLASS_COND(CAccessibleTable, IsMulticolumn());
IMPL_IUNKNOWN_QUERY_CLASS_COND(ia2AccessibleTable, IsMulticolumn());
IMPL_IUNKNOWN_QUERY_CLASS(AccessibleWrap)
IMPL_IUNKNOWN_QUERY_TAIL
@ -41,4 +41,4 @@ NS_IMPL_ISUPPORTS_INHERITED0(XULListCellAccessibleWrap,
IMPL_IUNKNOWN_INHERITED1(XULListCellAccessibleWrap,
HyperTextAccessibleWrap,
CAccessibleTableCell)
ia2AccessibleTableCell)

Просмотреть файл

@ -8,8 +8,8 @@
#include "XULListboxAccessible.h"
#include "CAccessibleTable.h"
#include "CAccessibleTableCell.h"
#include "ia2AccessibleTable.h"
#include "ia2AccessibleTableCell.h"
namespace mozilla {
namespace a11y {
@ -19,7 +19,7 @@ namespace a11y {
* IAccessibleTable and IAccessibleTable2 interfaces.
*/
class XULListboxAccessibleWrap : public XULListboxAccessible,
public CAccessibleTable
public ia2AccessibleTable
{
public:
XULListboxAccessibleWrap(nsIContent* aContent, DocAccessible* aDoc);
@ -36,7 +36,7 @@ public:
* IAccessibleTableCell interface.
*/
class XULListCellAccessibleWrap : public XULListCellAccessible,
public CAccessibleTableCell
public ia2AccessibleTableCell
{
public:
XULListCellAccessibleWrap(nsIContent* aContent, DocAccessible* aDoc);

Просмотреть файл

@ -22,7 +22,7 @@ NS_IMPL_ISUPPORTS_INHERITED0(XULTreeGridAccessibleWrap,
IMPL_IUNKNOWN_INHERITED1(XULTreeGridAccessibleWrap,
AccessibleWrap,
CAccessibleTable)
ia2AccessibleTable)
////////////////////////////////////////////////////////////////////////////////
@ -46,4 +46,4 @@ NS_IMPL_ISUPPORTS_INHERITED0(XULTreeGridCellAccessibleWrap,
IMPL_IUNKNOWN_INHERITED1(XULTreeGridCellAccessibleWrap,
AccessibleWrap,
CAccessibleTableCell)
ia2AccessibleTableCell)

Просмотреть файл

@ -8,8 +8,8 @@
#include "XULTreeGridAccessible.h"
#include "CAccessibleTable.h"
#include "CAccessibleTableCell.h"
#include "ia2AccessibleTable.h"
#include "ia2AccessibleTableCell.h"
namespace mozilla {
namespace a11y {
@ -19,7 +19,7 @@ namespace a11y {
* IAccessibleTable and IAccessibleTable2 interfaces.
*/
class XULTreeGridAccessibleWrap : public XULTreeGridAccessible,
public CAccessibleTable
public ia2AccessibleTable
{
public:
XULTreeGridAccessibleWrap(nsIContent* aContent, DocAccessible* aDoc);
@ -36,7 +36,7 @@ public:
* IAccessibleTableCell interface.
*/
class XULTreeGridCellAccessibleWrap : public XULTreeGridCellAccessible,
public CAccessibleTableCell
public ia2AccessibleTableCell
{
public:
XULTreeGridCellAccessibleWrap(nsIContent* aContent,

Просмотреть файл

@ -501,7 +501,7 @@ __try {
return E_FAIL; // Node already shut down
nsAutoString innerHTML;
htmlElement->GetInnerHTML(innerHTML);
htmlElement->GetDOMInnerHTML(innerHTML);
if (innerHTML.IsEmpty())
return S_FALSE;

Просмотреть файл

@ -10,7 +10,9 @@ VPATH = @srcdir@
include $(DEPTH)/config/autoconf.mk
DIRS += uia \
DIRS += \
ia2 \
uia \
$(null)
include $(topsrcdir)/config/rules.mk

Просмотреть файл

@ -0,0 +1,60 @@
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
DEPTH = @DEPTH@
topsrcdir = @top_srcdir@
srcdir = @srcdir@
VPATH = @srcdir@
include $(DEPTH)/config/autoconf.mk
MODULE = accessibility
LIBRARY_NAME = accessibility_toolkit_ia2_s
EXPORT_LIBRARY = 1
LIBXUL_LIBRARY = 1
CPPSRCS += \
ia2AccessibleAction.cpp \
ia2AccessibleComponent.cpp \
ia2AccessibleEditableText.cpp \
ia2AccessibleHyperlink.cpp \
ia2AccessibleHypertext.cpp \
ia2AccessibleImage.cpp \
ia2AccessibleRelation.cpp \
ia2AccessibleTable.cpp \
ia2AccessibleTableCell.cpp \
ia2AccessibleText.cpp \
ia2AccessibleValue.cpp \
$(NULL)
EXPORTS = \
ia2AccessibleValue.h \
ia2AccessibleAction.h \
ia2AccessibleComponent.h \
ia2AccessibleEditableText.h \
ia2AccessibleHyperlink.h \
ia2AccessibleHypertext.h \
ia2AccessibleText.h \
$(NULL)
# we don't want the shared lib, but we want to force the creation of a static lib.
FORCE_STATIC_LIB = 1
include $(topsrcdir)/config/config.mk
include $(topsrcdir)/config/rules.mk
LOCAL_INCLUDES += \
-I$(srcdir) \
-I$(srcdir)/../../base \
-I$(srcdir)/../../generic \
-I$(srcdir)/../../html \
-I$(srcdir)/../../msaa \
-I$(srcdir)/../../xpcom \
-I$(srcdir)/../../xul \
$(NULL)
ifdef A11Y_LOG
DEFINES += -DA11Y_LOG
endif

Просмотреть файл

@ -46,9 +46,6 @@ public:
/* [in] */ long startOffset,
/* [in] */ long endOffset,
/* [in] */ BSTR *attributes);
// nsISupports
NS_IMETHOD QueryInterface(const nsIID& uuid, void** result) = 0;
};
#endif

Просмотреть файл

@ -40,10 +40,6 @@ public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_valid(
/* [retval][out] */ boolean *valid);
// nsISupports
NS_IMETHOD QueryInterface(const nsIID& uuid, void** result) = 0;
};
#endif

Просмотреть файл

@ -32,9 +32,6 @@ public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_hyperlinkIndex(
/* [in] */ long charIndex,
/* [retval][out] */ long* hyperlinkIndex);
// nsISupports
NS_IMETHOD QueryInterface(const nsIID& uuid, void** result) = 0;
};
#endif

Просмотреть файл

@ -5,7 +5,7 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "CAccessibleTable.h"
#include "ia2AccessibleTable.h"
#include "Accessible2.h"
#include "AccessibleTable_i.c"
@ -24,12 +24,12 @@
using namespace mozilla::a11y;
#define CANT_QUERY_ASSERTION_MSG \
"Subclass of CAccessibleTable doesn't implement nsIAccessibleTable"\
"Subclass of ia2AccessibleTable doesn't implement nsIAccessibleTable"\
// IUnknown
STDMETHODIMP
CAccessibleTable::QueryInterface(REFIID iid, void** ppv)
ia2AccessibleTable::QueryInterface(REFIID iid, void** ppv)
{
*ppv = NULL;
@ -53,7 +53,7 @@ CAccessibleTable::QueryInterface(REFIID iid, void** ppv)
// IAccessibleTable
STDMETHODIMP
CAccessibleTable::get_accessibleAt(long aRow, long aColumn,
ia2AccessibleTable::get_accessibleAt(long aRow, long aColumn,
IUnknown **aAccessible)
{
__try {
@ -86,7 +86,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_caption(IUnknown **aAccessible)
ia2AccessibleTable::get_caption(IUnknown** aAccessible)
{
__try {
*aAccessible = NULL;
@ -121,8 +121,8 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_childIndex(long aRowIndex, long aColumnIndex,
long *aChildIndex)
ia2AccessibleTable::get_childIndex(long aRowIndex, long aColumnIndex,
long* aChildIndex)
{
__try {
*aChildIndex = 0;
@ -146,7 +146,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_columnDescription(long aColumn, BSTR *aDescription)
ia2AccessibleTable::get_columnDescription(long aColumn, BSTR* aDescription)
{
__try {
*aDescription = NULL;
@ -172,8 +172,8 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_columnExtentAt(long aRow, long aColumn,
long *nColumnsSpanned)
ia2AccessibleTable::get_columnExtentAt(long aRow, long aColumn,
long* nColumnsSpanned)
{
__try {
*nColumnsSpanned = 0;
@ -196,8 +196,8 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_columnHeader(IAccessibleTable **aAccessibleTable,
long *aStartingRowIndex)
ia2AccessibleTable::get_columnHeader(IAccessibleTable** aAccessibleTable,
long* aStartingRowIndex)
{
__try {
*aAccessibleTable = NULL;
@ -209,7 +209,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_columnIndex(long aChildIndex, long *aColumnIndex)
ia2AccessibleTable::get_columnIndex(long aChildIndex, long* aColumnIndex)
{
__try {
*aColumnIndex = 0;
@ -233,7 +233,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_nColumns(long *aColumnCount)
ia2AccessibleTable::get_nColumns(long* aColumnCount)
{
__try {
*aColumnCount = 0;
@ -257,7 +257,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_nRows(long *aRowCount)
ia2AccessibleTable::get_nRows(long* aRowCount)
{
__try {
*aRowCount = 0;
@ -281,7 +281,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_nSelectedChildren(long *aChildCount)
ia2AccessibleTable::get_nSelectedChildren(long* aChildCount)
{
__try {
*aChildCount = 0;
@ -304,7 +304,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_nSelectedColumns(long *aColumnCount)
ia2AccessibleTable::get_nSelectedColumns(long* aColumnCount)
{
__try {
*aColumnCount = 0;
@ -327,7 +327,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_nSelectedRows(long *aRowCount)
ia2AccessibleTable::get_nSelectedRows(long* aRowCount)
{
__try {
*aRowCount = 0;
@ -350,7 +350,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_rowDescription(long aRow, BSTR *aDescription)
ia2AccessibleTable::get_rowDescription(long aRow, BSTR* aDescription)
{
__try {
*aDescription = NULL;
@ -376,7 +376,8 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_rowExtentAt(long aRow, long aColumn, long *aNRowsSpanned)
ia2AccessibleTable::get_rowExtentAt(long aRow, long aColumn,
long* aNRowsSpanned)
{
__try {
*aNRowsSpanned = 0;
@ -399,8 +400,8 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_rowHeader(IAccessibleTable **aAccessibleTable,
long *aStartingColumnIndex)
ia2AccessibleTable::get_rowHeader(IAccessibleTable** aAccessibleTable,
long* aStartingColumnIndex)
{
__try {
*aAccessibleTable = NULL;
@ -412,7 +413,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_rowIndex(long aChildIndex, long *aRowIndex)
ia2AccessibleTable::get_rowIndex(long aChildIndex, long* aRowIndex)
{
__try {
*aRowIndex = 0;
@ -436,8 +437,8 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_selectedChildren(long aMaxChildren, long **aChildren,
long *aNChildren)
ia2AccessibleTable::get_selectedChildren(long aMaxChildren, long** aChildren,
long* aNChildren)
{
__try {
return GetSelectedItems(aChildren, aNChildren, ITEMSTYPE_CELLS);
@ -448,8 +449,8 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_selectedColumns(long aMaxColumns, long **aColumns,
long *aNColumns)
ia2AccessibleTable::get_selectedColumns(long aMaxColumns, long** aColumns,
long* aNColumns)
{
__try {
return GetSelectedItems(aColumns, aNColumns, ITEMSTYPE_COLUMNS);
@ -460,7 +461,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_selectedRows(long aMaxRows, long **aRows, long *aNRows)
ia2AccessibleTable::get_selectedRows(long aMaxRows, long** aRows, long* aNRows)
{
__try {
return GetSelectedItems(aRows, aNRows, ITEMSTYPE_ROWS);
@ -471,7 +472,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_summary(IUnknown **aAccessible)
ia2AccessibleTable::get_summary(IUnknown** aAccessible)
{
__try {
*aAccessible = NULL;
@ -486,7 +487,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_isColumnSelected(long aColumn, boolean *aIsSelected)
ia2AccessibleTable::get_isColumnSelected(long aColumn, boolean* aIsSelected)
{
__try {
*aIsSelected = false;
@ -509,7 +510,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_isRowSelected(long aRow, boolean *aIsSelected)
ia2AccessibleTable::get_isRowSelected(long aRow, boolean* aIsSelected)
{
__try {
*aIsSelected = false;
@ -532,7 +533,8 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_isSelected(long aRow, long aColumn, boolean *aIsSelected)
ia2AccessibleTable::get_isSelected(long aRow, long aColumn,
boolean* aIsSelected)
{
__try {
*aIsSelected = false;
@ -555,7 +557,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::selectRow(long aRow)
ia2AccessibleTable::selectRow(long aRow)
{
__try {
nsCOMPtr<nsIAccessibleTable> tableAcc(do_QueryObject(this));
@ -571,7 +573,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::selectColumn(long aColumn)
ia2AccessibleTable::selectColumn(long aColumn)
{
__try {
nsCOMPtr<nsIAccessibleTable> tableAcc(do_QueryObject(this));
@ -587,7 +589,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::unselectRow(long aRow)
ia2AccessibleTable::unselectRow(long aRow)
{
__try {
nsCOMPtr<nsIAccessibleTable> tableAcc(do_QueryObject(this));
@ -603,7 +605,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::unselectColumn(long aColumn)
ia2AccessibleTable::unselectColumn(long aColumn)
{
__try {
nsCOMPtr<nsIAccessibleTable> tableAcc(do_QueryObject(this));
@ -619,11 +621,11 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_rowColumnExtentsAtIndex(long aIndex, long *aRow,
long *aColumn,
long *aRowExtents,
long *aColumnExtents,
boolean *aIsSelected)
ia2AccessibleTable::get_rowColumnExtentsAtIndex(long aIndex, long* aRow,
long* aColumn,
long* aRowExtents,
long* aColumnExtents,
boolean* aIsSelected)
{
__try {
*aRow = 0;
@ -669,7 +671,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_modelChange(IA2TableModelChange *aModelChange)
ia2AccessibleTable::get_modelChange(IA2TableModelChange* aModelChange)
{
__try {
@ -681,19 +683,19 @@ __try {
// IAccessibleTable2
STDMETHODIMP
CAccessibleTable::get_cellAt(long row, long column, IUnknown **cell)
ia2AccessibleTable::get_cellAt(long aRow, long aColumn, IUnknown** aCell)
{
return get_accessibleAt(row, column, cell);
return get_accessibleAt(aRow, aColumn, aCell);
}
STDMETHODIMP
CAccessibleTable::get_nSelectedCells(long *cellCount)
ia2AccessibleTable::get_nSelectedCells(long* aCellCount)
{
return get_nSelectedChildren(cellCount);
return get_nSelectedChildren(aCellCount);
}
STDMETHODIMP
CAccessibleTable::get_selectedCells(IUnknown ***cells, long *nSelectedCells)
ia2AccessibleTable::get_selectedCells(IUnknown*** aCells, long* aNSelectedCells)
{
__try {
nsCOMPtr<nsIAccessibleTable> tableAcc(do_QueryObject(this));
@ -706,7 +708,7 @@ __try {
if (NS_FAILED(rv))
return GetHRESULT(rv);
return nsWinUtils::ConvertToIA2Array(geckoCells, cells, nSelectedCells);
return nsWinUtils::ConvertToIA2Array(geckoCells, aCells, aNSelectedCells);
} __except(nsAccessNodeWrap::FilterA11yExceptions(::GetExceptionCode(),
GetExceptionInformation())) {}
@ -715,7 +717,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_selectedColumns(long **aColumns, long *aNColumns)
ia2AccessibleTable::get_selectedColumns(long** aColumns, long* aNColumns)
{
__try {
return GetSelectedItems(aColumns, aNColumns, ITEMSTYPE_COLUMNS);
@ -726,7 +728,7 @@ __try {
}
STDMETHODIMP
CAccessibleTable::get_selectedRows(long **aRows, long *aNRows)
ia2AccessibleTable::get_selectedRows(long** aRows, long* aNRows)
{
__try {
return GetSelectedItems(aRows, aNRows, ITEMSTYPE_ROWS);
@ -737,10 +739,10 @@ __try {
}
////////////////////////////////////////////////////////////////////////////////
// CAccessibleTable public
// ia2AccessibleTable public
HRESULT
CAccessibleTable::GetSelectedItems(long **aItems, long *aItemsCount,
ia2AccessibleTable::GetSelectedItems(long** aItems, long* aItemsCount,
eItemsType aType)
{
*aItemsCount = 0;

Просмотреть файл

@ -13,7 +13,7 @@
#include "AccessibleTable.h"
#include "AccessibleTable2.h"
class CAccessibleTable: public IAccessibleTable,
class ia2AccessibleTable : public IAccessibleTable,
public IAccessibleTable2
{
public:

Просмотреть файл

@ -5,7 +5,7 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "CAccessibleTableCell.h"
#include "ia2AccessibleTableCell.h"
#include "Accessible2.h"
#include "AccessibleTable2_i.c"
@ -21,12 +21,12 @@
#include "nsString.h"
#define TABLECELL_INTERFACE_UNSUPPORTED_MSG \
"Subclass of CAccessibleTableCell doesn't implement nsIAccessibleTableCell"\
"Subclass of ia2AccessibleTableCell doesn't implement nsIAccessibleTableCell"\
// IUnknown
STDMETHODIMP
CAccessibleTableCell::QueryInterface(REFIID iid, void** ppv)
ia2AccessibleTableCell::QueryInterface(REFIID iid, void** ppv)
{
*ppv = NULL;
@ -43,7 +43,7 @@ CAccessibleTableCell::QueryInterface(REFIID iid, void** ppv)
// IAccessibleTableCell
STDMETHODIMP
CAccessibleTableCell::get_table(IUnknown **table)
ia2AccessibleTableCell::get_table(IUnknown** aTable)
{
__try {
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
@ -65,7 +65,7 @@ __try {
if (NS_FAILED(rv))
return GetHRESULT(rv);
*table = static_cast<IUnknown*>(instancePtr);
*aTable = static_cast<IUnknown*>(instancePtr);
return S_OK;
} __except(nsAccessNodeWrap::FilterA11yExceptions(::GetExceptionCode(),
@ -75,10 +75,10 @@ __try {
}
STDMETHODIMP
CAccessibleTableCell::get_columnExtent(long *nColumnsSpanned)
ia2AccessibleTableCell::get_columnExtent(long* aNColumnsSpanned)
{
__try {
*nColumnsSpanned = 0;
*aNColumnsSpanned = 0;
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
NS_ASSERTION(tableCell, TABLECELL_INTERFACE_UNSUPPORTED_MSG);
@ -88,7 +88,7 @@ __try {
int32_t columnsSpanned = 0;
nsresult rv = tableCell->GetColumnExtent(&columnsSpanned);
if (NS_SUCCEEDED(rv)) {
*nColumnsSpanned = columnsSpanned;
*aNColumnsSpanned = columnsSpanned;
return S_OK;
}
@ -101,8 +101,8 @@ __try {
}
STDMETHODIMP
CAccessibleTableCell::get_columnHeaderCells(IUnknown ***cellAccessibles,
long *nColumnHeaderCells)
ia2AccessibleTableCell::get_columnHeaderCells(IUnknown*** aCellAccessibles,
long* aNColumnHeaderCells)
{
__try {
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
@ -115,8 +115,8 @@ __try {
if (NS_FAILED(rv))
return GetHRESULT(rv);
return nsWinUtils::ConvertToIA2Array(headerCells, cellAccessibles,
nColumnHeaderCells);
return nsWinUtils::ConvertToIA2Array(headerCells, aCellAccessibles,
aNColumnHeaderCells);
} __except(nsAccessNodeWrap::FilterA11yExceptions(::GetExceptionCode(),
GetExceptionInformation())) {}
@ -125,10 +125,10 @@ __try {
}
STDMETHODIMP
CAccessibleTableCell::get_columnIndex(long *columnIndex)
ia2AccessibleTableCell::get_columnIndex(long* aColumnIndex)
{
__try {
*columnIndex = -1;
*aColumnIndex = -1;
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
NS_ASSERTION(tableCell, TABLECELL_INTERFACE_UNSUPPORTED_MSG);
@ -138,7 +138,7 @@ __try {
int32_t colIdx = -1;
nsresult rv = tableCell->GetColumnIndex(&colIdx);
if (NS_SUCCEEDED(rv)) {
*columnIndex = colIdx;
*aColumnIndex = colIdx;
return S_OK;
}
@ -151,10 +151,10 @@ __try {
}
STDMETHODIMP
CAccessibleTableCell::get_rowExtent(long *nRowsSpanned)
ia2AccessibleTableCell::get_rowExtent(long* aNRowsSpanned)
{
__try {
*nRowsSpanned = 0;
*aNRowsSpanned = 0;
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
NS_ASSERTION(tableCell, TABLECELL_INTERFACE_UNSUPPORTED_MSG);
@ -164,7 +164,7 @@ __try {
int32_t rowsSpanned = 0;
nsresult rv = tableCell->GetRowExtent(&rowsSpanned);
if (NS_SUCCEEDED(rv)) {
*nRowsSpanned = rowsSpanned;
*aNRowsSpanned = rowsSpanned;
return S_OK;
}
@ -177,8 +177,8 @@ __try {
}
STDMETHODIMP
CAccessibleTableCell::get_rowHeaderCells(IUnknown ***cellAccessibles,
long *nRowHeaderCells)
ia2AccessibleTableCell::get_rowHeaderCells(IUnknown*** aCellAccessibles,
long* aNRowHeaderCells)
{
__try {
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
@ -191,8 +191,8 @@ __try {
if (NS_FAILED(rv))
return GetHRESULT(rv);
return nsWinUtils::ConvertToIA2Array(headerCells, cellAccessibles,
nRowHeaderCells);
return nsWinUtils::ConvertToIA2Array(headerCells, aCellAccessibles,
aNRowHeaderCells);
} __except(nsAccessNodeWrap::FilterA11yExceptions(::GetExceptionCode(),
GetExceptionInformation())) {}
@ -201,10 +201,10 @@ __try {
}
STDMETHODIMP
CAccessibleTableCell::get_rowIndex(long *rowIndex)
ia2AccessibleTableCell::get_rowIndex(long* aRowIndex)
{
__try {
*rowIndex = -1;
*aRowIndex = -1;
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
NS_ASSERTION(tableCell, TABLECELL_INTERFACE_UNSUPPORTED_MSG);
@ -214,7 +214,7 @@ __try {
int32_t rowIdx = -1;
nsresult rv = tableCell->GetRowIndex(&rowIdx);
if (NS_SUCCEEDED(rv)) {
*rowIndex = rowIdx;
*aRowIndex = rowIdx;
return S_OK;
}
@ -227,17 +227,17 @@ __try {
}
STDMETHODIMP
CAccessibleTableCell::get_rowColumnExtents(long *row, long *column,
long *rowExtents,
long *columnExtents,
boolean *isSelected)
ia2AccessibleTableCell::get_rowColumnExtents(long* aRow, long* aColumn,
long* aRowExtents,
long* aColumnExtents,
boolean* aIsSelected)
{
__try {
*row = 0;
*column = 0;
*rowExtents = 0;
*columnExtents = 0;
*isSelected = false;
*aRow = 0;
*aRow = 0;
*aRow = 0;
*aColumnExtents = 0;
*aIsSelected = false;
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
NS_ASSERTION(tableCell, TABLECELL_INTERFACE_UNSUPPORTED_MSG);
@ -269,11 +269,11 @@ __try {
if (NS_FAILED(rv))
return GetHRESULT(rv);
*row = rowIdx;
*column = columnIdx;
*rowExtents = spannedRows;
*columnExtents = spannedColumns;
*isSelected = isSel;
*aRow = rowIdx;
*aColumn = columnIdx;
*aRowExtents = spannedRows;
*aColumnExtents = spannedColumns;
*aIsSelected = isSel;
return S_OK;
} __except(nsAccessNodeWrap::FilterA11yExceptions(::GetExceptionCode(),
@ -282,10 +282,10 @@ __try {
}
STDMETHODIMP
CAccessibleTableCell::get_isSelected(boolean *isSelected)
ia2AccessibleTableCell::get_isSelected(boolean* aIsSelected)
{
__try {
*isSelected = false;
*aIsSelected = false;
nsCOMPtr<nsIAccessibleTableCell> tableCell(do_QueryObject(this));
NS_ASSERTION(tableCell, TABLECELL_INTERFACE_UNSUPPORTED_MSG);
@ -295,7 +295,7 @@ __try {
bool isSel = false;
nsresult rv = tableCell->IsSelected(&isSel);
if (NS_SUCCEEDED(rv)) {
*isSelected = isSel;
*aIsSelected = isSel;
return S_OK;
}

Просмотреть файл

@ -12,7 +12,7 @@
#include "AccessibleTableCell.h"
class CAccessibleTableCell: public IAccessibleTableCell
class ia2AccessibleTableCell : public IAccessibleTableCell
{
public:

Просмотреть файл

@ -111,9 +111,6 @@ public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_oldText(
/* [retval][out] */ IA2TextSegment *oldText);
// nsISupports
NS_IMETHOD QueryInterface(const nsIID& uuid, void** result) = 0;
protected:
virtual nsresult GetModifiedText(bool aGetInsertedText, nsAString& aText,
uint32_t *aStartOffset,

Просмотреть файл

@ -5,47 +5,44 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "CAccessibleValue.h"
#include "ia2AccessibleValue.h"
#include "AccessibleValue_i.c"
#include "nsIAccessibleValue.h"
#include "nsCOMPtr.h"
#include "nsAccessNodeWrap.h"
#include "AccessibleWrap.h"
// IUnknown
STDMETHODIMP
CAccessibleValue::QueryInterface(REFIID iid, void** ppv)
ia2AccessibleValue::QueryInterface(REFIID iid, void** ppv)
{
*ppv = NULL;
if (IID_IAccessibleValue == iid) {
nsCOMPtr<nsIAccessibleValue> valueAcc(do_QueryObject(this));
if (!valueAcc)
return E_NOINTERFACE;
AccessibleWrap* valueAcc = static_cast<AccessibleWrap*>(this);
if (valueAcc->HasNumericValue()) {
*ppv = static_cast<IAccessibleValue*>(this);
(reinterpret_cast<IUnknown*>(*ppv))->AddRef();
valueAcc->AddRef();
return S_OK;
}
return E_NOINTERFACE;
}
return E_NOINTERFACE;
}
// IAccessibleValue
STDMETHODIMP
CAccessibleValue::get_currentValue(VARIANT *aCurrentValue)
ia2AccessibleValue::get_currentValue(VARIANT* aCurrentValue)
{
__try {
VariantInit(aCurrentValue);
nsCOMPtr<nsIAccessibleValue> valueAcc(do_QueryObject(this));
if (!valueAcc)
return E_FAIL;
AccessibleWrap* valueAcc = static_cast<AccessibleWrap*>(this);
if (valueAcc->IsDefunct())
return CO_E_OBJNOTCONNECTED;
double currentValue = 0;
nsresult rv = valueAcc->GetCurrentValue(&currentValue);
@ -61,12 +58,12 @@ __try {
}
STDMETHODIMP
CAccessibleValue::setCurrentValue(VARIANT aValue)
ia2AccessibleValue::setCurrentValue(VARIANT aValue)
{
__try {
nsCOMPtr<nsIAccessibleValue> valueAcc(do_QueryObject(this));
if (!valueAcc)
return E_FAIL;
AccessibleWrap* valueAcc = static_cast<AccessibleWrap*>(this);
if (valueAcc->IsDefunct())
return CO_E_OBJNOTCONNECTED;
if (aValue.vt != VT_R8)
return E_INVALIDARG;
@ -79,14 +76,14 @@ __try {
}
STDMETHODIMP
CAccessibleValue::get_maximumValue(VARIANT *aMaximumValue)
ia2AccessibleValue::get_maximumValue(VARIANT* aMaximumValue)
{
__try {
VariantInit(aMaximumValue);
nsCOMPtr<nsIAccessibleValue> valueAcc(do_QueryObject(this));
if (!valueAcc)
return E_FAIL;
AccessibleWrap* valueAcc = static_cast<AccessibleWrap*>(this);
if (valueAcc->IsDefunct())
return CO_E_OBJNOTCONNECTED;
double maximumValue = 0;
nsresult rv = valueAcc->GetMaximumValue(&maximumValue);
@ -102,14 +99,14 @@ __try {
}
STDMETHODIMP
CAccessibleValue::get_minimumValue(VARIANT *aMinimumValue)
ia2AccessibleValue::get_minimumValue(VARIANT* aMinimumValue)
{
__try {
VariantInit(aMinimumValue);
nsCOMPtr<nsIAccessibleValue> valueAcc(do_QueryObject(this));
if (!valueAcc)
return E_FAIL;
AccessibleWrap* valueAcc = static_cast<AccessibleWrap*>(this);
if (valueAcc->IsDefunct())
return CO_E_OBJNOTCONNECTED;
double minimumValue = 0;
nsresult rv = valueAcc->GetMinimumValue(&minimumValue);

Просмотреть файл

@ -8,11 +8,9 @@
#ifndef _ACCESSIBLE_VALUE_H
#define _ACCESSIBLE_VALUE_H
#include "nsISupports.h"
#include "AccessibleValue.h"
class CAccessibleValue: public IAccessibleValue
class ia2AccessibleValue: public IAccessibleValue
{
public:
@ -32,9 +30,6 @@ public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_minimumValue(
/* [retval][out] */ VARIANT *minimumValue);
// nsISupports
NS_IMETHOD QueryInterface(const nsIID& uuid, void** result) = 0;
};
#endif

Просмотреть файл

@ -54,6 +54,7 @@ else
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
LOCAL_INCLUDES += \
-I$(srcdir)/../msaa \
-I$(srcdir)/../windows/ia2 \
$(NULL)
else
ifeq ($(MOZ_WIDGET_TOOLKIT),cocoa)

Просмотреть файл

@ -21,19 +21,11 @@
src="../events.js" />
<script type="application/javascript">
//gA11yEventDumpID = "eventdump"; // debug stuff
//gA11yEventDumpToConsole = true; // debug stuff
var gQueue = null;
function doTests()
{
// bug 708927 - test times out on Linux
if (LINUX) {
todo(false, "Reenable on Linux after fixing bug 708927!");
SimpleTest.finish();
return;
}
// Test focus events.
gQueue = new eventQueue();
@ -67,6 +59,13 @@
gQueue.push(new synthClick("vehicle", new focusChecker("vehicle")));
gQueue.push(new synthMouseMove("cycle", new focusChecker("cycle")));
// XXXbug708927 - test times out on Linux, see more info at
// https://bugzilla.mozilla.org/show_bug.cgi?id=708927#c360. If needed
// then enable logging below.
if (LINUX) {
todo(false, "Reenable on Linux after fixing bug 708927!");
} else {
// open submenu
gQueue.push(new synthRightKey("cycle", new focusChecker("tricycle")));
@ -78,6 +77,11 @@
// click menuitem to close menu, focus gets back to document
gQueue.push(new synthClick("tricycle", new focusChecker(document)));
}
//enableLogging("focus,DOMEvents,tree"); // logging for bug708927
//gQueue.onFinish = function() { disableLogging(); }
gQueue.invoke(); // Will call SimpleTest.finish();
}

Просмотреть файл

@ -121,10 +121,9 @@ var shell = {
},
start: function shell_start() {
try {
let cr = Cc["@mozilla.org/xre/app-info;1"]
.getService(Ci.nsICrashReporter);
try {
// Dogfood id. We might want to remove it in the future.
// see bug 789466
try {

Просмотреть файл

@ -1,6 +1,6 @@
[
{
"clang_version": "r162360"
"clang_version": "r163716"
},
{
"size": 47,
@ -9,8 +9,8 @@
"filename": "setup.sh"
},
{
"size": 54372252,
"digest": "e4b198da311aa851b14a65a392b1f429d0df942bd6167887e389c89fbdbd46c00d3d09f88923f8b2bf6c41c3ab9ea87de54473deb3b6b0a71eb4146d483ba035",
"size": 54033946,
"digest": "50eb6fa636403f444bab10aee2370f1ac624a1e0105566639c7c266e784dbc6e4cd3901bbd11f53c4c63b2a6d2d07a603b3d9c333f5049bdc7a816b7d225631b",
"algorithm": "sha512",
"filename": "clang.tar.bz2"
}

Просмотреть файл

@ -383,6 +383,7 @@ pref("browser.tabs.autoHide", false);
pref("browser.tabs.closeWindowWithLastTab", true);
pref("browser.tabs.insertRelatedAfterCurrent", true);
pref("browser.tabs.warnOnClose", true);
pref("browser.tabs.warnOnCloseOtherTabs", true);
pref("browser.tabs.warnOnOpen", true);
pref("browser.tabs.maxOpenBeforeWarn", 15);
pref("browser.tabs.loadInBackground", true);

Просмотреть файл

@ -27,7 +27,7 @@
</div>
<div id="button-box">
<button id="btnTryAgain" onclick="tryAgainButton()"/>
<button id="btnCloseSidebar" onclick="closeSidebar()"/>
<button id="btnCloseSidebar" onclick="closeSidebarButton()"/>
</div>
</body>
@ -35,7 +35,7 @@
const Cu = Components.utils;
Cu.import("resource://gre/modules/Services.jsm");
Cu.import("resource://gre/modules/Social.jsm");
Cu.import("resource:///modules/Social.jsm");
let config = {
tryAgainCallback: reloadProvider
@ -49,8 +49,20 @@
let mode = modeMatch && modeMatch[1] ? modeMatch[1] : "";
switch (mode) {
case "onlyRefreshSidebar":
config.tryAgainCallback = refreshSidebar;
case "compactInfo":
document.getElementById("btnTryAgain").style.display = 'none';
document.getElementById("btnCloseSidebar").style.display = 'none';
break;
case "tryAgainOnly":
document.getElementById("btnCloseSidebar").style.display = 'none';
//intentional fall-through
case "tryAgain":
let urlMatch = queryString.match(/url=([^&]+)/);
let encodedURL = urlMatch && urlMatch[1] ? urlMatch[1] : "";
let url = decodeURIComponent(encodedURL);
config.tryAgainCallback = loadQueryURL;
config.queryURL = url;
break;
default:
break;
@ -78,22 +90,22 @@
btnCloseSidebar.accessKey = browserBundle.GetStringFromName("social.error.closeSidebar.accesskey");
}
function closeSidebar() {
function closeSidebarButton() {
Social.toggleSidebar();
}
function refreshSidebar() {
window.location.href = Social.provider.sidebarURL;
}
function reloadProvider() {
Social.provider.reload();
}
function tryAgainButton() {
config.tryAgainCallback();
}
function loadQueryURL() {
window.location.href = config.queryURL;
}
function reloadProvider() {
Social.provider.reload();
}
parseQueryString();
setUpStrings();
]]></script>

Просмотреть файл

@ -276,6 +276,30 @@ let SocialFlyout = {
panel.appendChild(iframe);
},
setUpProgressListener: function SF_setUpProgressListener() {
if (!this._progressListenerSet) {
this._progressListenerSet = true;
// Force a layout flush by calling .clientTop so
// that the docShell of this frame is created
this.panel.firstChild.clientTop;
this.panel.firstChild.docShell.QueryInterface(Ci.nsIInterfaceRequestor)
.getInterface(Ci.nsIWebProgress)
.addProgressListener(new SocialErrorListener("flyout"),
Ci.nsIWebProgress.NOTIFY_STATE_REQUEST |
Ci.nsIWebProgress.NOTIFY_LOCATION);
}
},
setFlyoutErrorMessage: function SF_setFlyoutErrorMessage() {
let iframe = this.panel.firstChild;
if (!iframe)
return;
iframe.removeAttribute("src");
iframe.webNavigation.loadURI("about:socialerror?mode=compactInfo", null, null, null, null);
sizeSocialPanelToContent(iframe);
},
unload: function() {
let panel = this.panel;
panel.hidePopup();
@ -354,6 +378,7 @@ let SocialFlyout = {
panel.moveTo(box.screenX, box.screenY + yAdjust);
} else {
panel.openPopup(anchor, "start_before", 0, yOffset, false, false);
this.setUpProgressListener();
}
this.yOffset = yOffset;
}
@ -607,6 +632,8 @@ var SocialToolbar = {
let notificationFrames = document.createDocumentFragment();
let iconContainers = document.createDocumentFragment();
let createdFrames = [];
let command = document.getElementById("Social:ToggleNotifications");
command.setAttribute("checked", Services.prefs.getBoolPref("social.toast-notifications.enabled"));
@ -624,6 +651,8 @@ var SocialToolbar = {
// work around bug 793057 - by making the panel roughly the final size
// we are more likely to have the anchor in the correct position.
notificationFrame.style.width = PANEL_MIN_WIDTH + "px";
createdFrames.push(notificationFrame);
notificationFrames.appendChild(notificationFrame);
}
notificationFrame.setAttribute("origin", provider.origin);
@ -654,6 +683,7 @@ var SocialToolbar = {
stack.classList.add("toolbarbutton-icon");
image = document.createElement("image");
image.setAttribute("id", imageId);
image.classList.add("social-notification-icon-image");
image = stack.appendChild(image);
label = document.createElement("label");
label.setAttribute("id", labelId);
@ -678,6 +708,17 @@ var SocialToolbar = {
}
notifBox.appendChild(notificationFrames);
iconBox.appendChild(iconContainers);
for (let frame of createdFrames) {
if (frame.docShell) {
frame.docShell.isActive = false;
frame.docShell.QueryInterface(Ci.nsIInterfaceRequestor)
.getInterface(Ci.nsIWebProgress)
.addProgressListener(new SocialErrorListener("notification-panel"),
Ci.nsIWebProgress.NOTIFY_STATE_REQUEST |
Ci.nsIWebProgress.NOTIFY_LOCATION);
}
}
},
showAmbientPopup: function SocialToolbar_showAmbientPopup(aToolbarButtonBox) {
@ -732,6 +773,17 @@ var SocialToolbar = {
let imageId = aToolbarButtonBox.getAttribute("id") + "-image";
let toolbarButtonImage = document.getElementById(imageId);
panel.openPopup(toolbarButtonImage, "bottomcenter topleft", 0, 0, false, false);
},
setPanelErrorMessage: function SocialToolbar_setPanelErrorMessage(aNotificationFrame) {
if (!aNotificationFrame)
return;
let src = aNotificationFrame.getAttribute("src");
aNotificationFrame.removeAttribute("src");
aNotificationFrame.webNavigation.loadURI("about:socialerror?mode=tryAgainOnly&url=" +
encodeURIComponent(src), null, null, null, null);
sizeSocialPanelToContent(aNotificationFrame);
}
}
@ -741,7 +793,9 @@ var SocialSidebar = {
let sbrowser = document.getElementById("social-sidebar-browser");
// setting isAppTab causes clicks on untargeted links to open new tabs
sbrowser.docShell.isAppTab = true;
sbrowser.webProgress.addProgressListener(new SocialErrorListener("sidebar"),
Ci.nsIWebProgress.NOTIFY_STATE_REQUEST |
Ci.nsIWebProgress.NOTIFY_LOCATION);
this.updateSidebar();
},
@ -807,5 +861,76 @@ var SocialSidebar = {
this.dispatchEvent("socialFrameShow");
}
}
},
setSidebarErrorMessage: function() {
let sbrowser = document.getElementById("social-sidebar-browser");
let url = encodeURIComponent(Social.provider.sidebarURL);
sbrowser.loadURI("about:socialerror?mode=tryAgain&url=" + url, null, null);
}
}
// Error handling class used to listen for network errors in the social frames
// and replace them with a social-specific error page
function SocialErrorListener(aType) {
this.type = aType;
}
SocialErrorListener.prototype = {
QueryInterface: XPCOMUtils.generateQI([Ci.nsIWebProgressListener,
Ci.nsISupportsWeakReference,
Ci.nsISupports]),
onStateChange: function SPL_onStateChange(aWebProgress, aRequest, aState, aStatus) {
let failure = false;
if ((aState & Ci.nsIWebProgressListener.STATE_STOP)) {
if (aRequest instanceof Ci.nsIHttpChannel) {
try {
// Change the frame to an error page on 4xx (client errors)
// and 5xx (server errors)
failure = aRequest.responseStatus >= 400 &&
aRequest.responseStatus < 600;
} catch (e) {}
}
}
// Calling cancel() will raise some OnStateChange notifications by itself,
// so avoid doing that more than once
if (failure && aStatus != Components.results.NS_BINDING_ABORTED) {
aRequest.cancel(Components.results.NS_BINDING_ABORTED);
this.setErrorMessage(aWebProgress);
}
},
onLocationChange: function SPL_onLocationChange(aWebProgress, aRequest, aLocation, aFlags) {
let failure = aFlags & Ci.nsIWebProgressListener.LOCATION_CHANGE_ERROR_PAGE;
if (failure) {
aRequest.cancel(Components.results.NS_BINDING_ABORTED);
window.setTimeout(function(self) {
self.setErrorMessage(aWebProgress);
}, 0, this);
}
},
onProgressChange: function SPL_onProgressChange() {},
onStatusChange: function SPL_onStatusChange() {},
onSecurityChange: function SPL_onSecurityChange() {},
setErrorMessage: function(aWebProgress) {
switch (this.type) {
case "flyout":
SocialFlyout.setFlyoutErrorMessage();
break;
case "sidebar":
SocialSidebar.setSidebarErrorMessage();
break;
case "notification-panel":
let frame = aWebProgress.QueryInterface(Ci.nsIDocShell)
.chromeEventHandler;
SocialToolbar.setPanelErrorMessage(frame);
break;
}
}
};

Просмотреть файл

@ -4016,6 +4016,7 @@ var XULBrowserWindow = {
},
onLocationChange: function (aWebProgress, aRequest, aLocationURI, aFlags) {
const nsIWebProgressListener = Ci.nsIWebProgressListener;
var location = aLocationURI ? aLocationURI.spec : "";
this._hostChanged = true;
@ -4125,22 +4126,46 @@ var XULBrowserWindow = {
document.documentElement.removeAttribute("disablechrome");
}
// Disable find commands in documents that ask for them to be disabled.
let disableFind = false;
if (aLocationURI &&
(aLocationURI.schemeIs("about") || aLocationURI.schemeIs("chrome"))) {
let docElt = content.document.documentElement;
disableFind = docElt && docElt.getAttribute("disablefastfind") == "true";
// Utility functions for disabling find
function shouldDisableFind(aDocument) {
let docElt = aDocument.documentElement;
return docElt && docElt.getAttribute("disablefastfind") == "true";
}
function disableFindCommands(aDisable) {
let findCommands = [document.getElementById("cmd_find"),
document.getElementById("cmd_findAgain"),
document.getElementById("cmd_findPrevious")];
for (let elt of findCommands) {
if (disableFind)
if (aDisable)
elt.setAttribute("disabled", "true");
else
elt.removeAttribute("disabled");
}
}
function onContentRSChange(e) {
if (e.target.readyState != "interactive" && e.target.readyState != "complete")
return;
e.target.removeEventListener("readystate", onContentRSChange);
disableFindCommands(shouldDisableFind(e.target));
}
// Disable find commands in documents that ask for them to be disabled.
if (aLocationURI &&
(aLocationURI.schemeIs("about") || aLocationURI.schemeIs("chrome"))) {
// Don't need to re-enable/disable find commands for same-document location changes
// (e.g. the replaceStates in about:addons)
if (!(aFlags & nsIWebProgressListener.LOCATION_CHANGE_SAME_DOCUMENT)) {
if (content.document.readyState == 'interactive' || content.document.readyState == "complete")
disableFindCommands(shouldDisableFind(content.document));
else {
content.document.addEventListener("readystatechange", onContentRSChange);
}
}
} else
disableFindCommands(false);
if (gFindBarInitialized) {
if (gFindBar.findMode != gFindBar.FIND_NORMAL) {

Просмотреть файл

@ -1450,9 +1450,10 @@
if (tabsToClose <= 1)
return true;
var canDisablePrompt = !!aAll;
const pref = "browser.tabs.warnOnClose";
if (canDisablePrompt && !Services.prefs.getBoolPref(pref))
const pref = aAll ?
"browser.tabs.warnOnClose" : "browser.tabs.warnOnCloseOtherTabs";
var shouldPrompt = Services.prefs.getBoolPref(pref);
if (!shouldPrompt)
return true;
var ps = Services.prompt;
@ -1476,13 +1477,13 @@
+ (ps.BUTTON_TITLE_CANCEL * ps.BUTTON_POS_1),
bundle.getString("tabs.closeButtonMultiple"),
null, null,
canDisablePrompt ?
aAll ?
bundle.getString("tabs.closeWarningPromptMe") : null,
warnOnClose);
var reallyClose = (buttonPressed == 0);
// don't set the pref unless they press OK and it's false
if (canDisablePrompt && reallyClose && !warnOnClose.value)
if (aAll && reallyClose && !warnOnClose.value)
Services.prefs.setBoolPref(pref, false);
return reallyClose;

Просмотреть файл

@ -7,6 +7,9 @@ var gTab = null;
function load(url, cb) {
gTab = gBrowser.addTab(url);
gBrowser.addEventListener("load", function (event) {
if (event.target.location != url)
return;
gBrowser.removeEventListener("load", arguments.callee, true);
// Trigger onLocationChange by switching tabs.
gBrowser.selectedTab = gTab;

Двоичные данные
browser/branding/aurora/appname.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 12 KiB

После

Ширина:  |  Высота:  |  Размер: 8.9 KiB

Двоичные данные
browser/branding/aurora/bgintro.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 666 KiB

После

Ширина:  |  Высота:  |  Размер: 666 KiB

Двоичные данные
browser/branding/aurora/bgplain.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 666 KiB

После

Ширина:  |  Высота:  |  Размер: 666 KiB

Просмотреть файл

@ -19,3 +19,26 @@
# The installer's certificate name and issuer expected by the stub installer
!define CertNameDownload "Mozilla Corporation"
!define CertIssuerDownload "Thawte Code Signing CA - G2"
# Dialog units are used so the UI displays correctly with the system's DPI
# settings.
# The dialog units for the bitmap's dimensions should match exactly with the
# bitmap's width and height in pixels.
!define APPNAME_BMP_WIDTH_DU 157u
!define APPNAME_BMP_HEIGHT_DU 21u
!define INTRO_BLURB_WIDTH_DU "232u"
!define INTRO_BLURB_EDGE_DU "196u"
!define INTRO_BLURB_LTR_TOP_DU "16u"
!define INTRO_BLURB_RTL_TOP_DU "11u"
# UI Colors that can be customized for each channel
!define FOOTER_CONTROL_TEXT_COLOR_NORMAL 0x000000
!define FOOTER_CONTROL_TEXT_COLOR_FADED 0x999999
!define FOOTER_BKGRD_COLOR 0xFFFFFF
!define INTRO_BLURB_TEXT_COLOR 0xFFFFFF
!define OPTIONS_TEXT_COLOR_NORMAL 0xFFFFFF
!define OPTIONS_TEXT_COLOR_FADED 0xA1AAB3
!define OPTIONS_BKGRD_COLOR 0x0F1B26
!define INSTALL_BLURB_TEXT_COLOR 0xFFFFFF
!define INSTALL_PROGRESS_TEXT_COLOR_NORMAL 0xFFFFFF
!define INSTALL_PROGRESS_TEXT_COLOR_FADED 0xA1AAB3

Двоичные данные
browser/branding/aurora/clock.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/aurora/particles.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/aurora/pencil-rtl.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/aurora/pencil.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/nightly/appname.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 12 KiB

После

Ширина:  |  Высота:  |  Размер: 11 KiB

Двоичные данные
browser/branding/nightly/bgintro.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 666 KiB

После

Ширина:  |  Высота:  |  Размер: 666 KiB

Двоичные данные
browser/branding/nightly/bgplain.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 666 KiB

После

Ширина:  |  Высота:  |  Размер: 666 KiB

Просмотреть файл

@ -19,3 +19,26 @@
# The installer's certificate name and issuer expected by the stub installer
!define CertNameDownload "Mozilla Corporation"
!define CertIssuerDownload "Thawte Code Signing CA - G2"
# Dialog units are used so the UI displays correctly with the system's DPI
# settings.
# The dialog units for the bitmap's dimensions should match exactly with the
# bitmap's width and height in pixels.
!define APPNAME_BMP_WIDTH_DU 159u
!define APPNAME_BMP_HEIGHT_DU 26u
!define INTRO_BLURB_WIDTH_DU "230u"
!define INTRO_BLURB_EDGE_DU "198u"
!define INTRO_BLURB_LTR_TOP_DU "16u"
!define INTRO_BLURB_RTL_TOP_DU "11u"
# UI Colors that can be customized for each channel
!define FOOTER_CONTROL_TEXT_COLOR_NORMAL 0x000000
!define FOOTER_CONTROL_TEXT_COLOR_FADED 0x999999
!define FOOTER_BKGRD_COLOR 0xFFFFFF
!define INTRO_BLURB_TEXT_COLOR 0xFFFFFF
!define OPTIONS_TEXT_COLOR_NORMAL 0xFFFFFF
!define OPTIONS_TEXT_COLOR_FADED 0xA1AAB3
!define OPTIONS_BKGRD_COLOR 0x0F1B26
!define INSTALL_BLURB_TEXT_COLOR 0xFFFFFF
!define INSTALL_PROGRESS_TEXT_COLOR_NORMAL 0xFFFFFF
!define INSTALL_PROGRESS_TEXT_COLOR_FADED 0xA1AAB3

Двоичные данные
browser/branding/nightly/clock.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/nightly/particles.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/nightly/pencil-rtl.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/nightly/pencil.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Просмотреть файл

@ -13,9 +13,35 @@
!define URLInfoAbout "http://www.mozilla.com/${AB_CD}/"
!define URLUpdateInfo "http://www.mozilla.com/${AB_CD}/firefox/"
; Prevents the beta channel urls in stub.nsi from being used when not using
; official branding
!define Official
!define URLStubDownload "http://download.mozilla.org/?product=firefox-latest&os=win&lang=${AB_CD}"
!define URLManualDownload "http://download.mozilla.org/?product=firefox-latest&os=win&lang=${AB_CD}"
!define URLManualDownload "https://www.mozilla.org/firefox/installer-help/"
# The installer's certificate name and issuer expected by the stub installer
!define CertNameDownload "Mozilla Corporation"
!define CertIssuerDownload "Thawte Code Signing CA - G2"
# Dialog units are used so the UI displays correctly with the system's DPI
# settings.
# The dialog units for the bitmap's dimensions should match exactly with the
# bitmap's width and height in pixels.
!define APPNAME_BMP_WIDTH_DU "134u"
!define APPNAME_BMP_HEIGHT_DU "36u"
!define INTRO_BLURB_WIDTH_DU "258u"
!define INTRO_BLURB_EDGE_DU "170u"
!define INTRO_BLURB_LTR_TOP_DU "20u"
!define INTRO_BLURB_RTL_TOP_DU "12u"
# UI Colors that can be customized for each channel
!define FOOTER_CONTROL_TEXT_COLOR_NORMAL 0x000000
!define FOOTER_CONTROL_TEXT_COLOR_FADED 0x666666
!define FOOTER_BKGRD_COLOR 0xFFFFFF
!define INTRO_BLURB_TEXT_COLOR 0x666666
!define OPTIONS_TEXT_COLOR_NORMAL 0x000000
!define OPTIONS_TEXT_COLOR_FADED 0x666666
!define OPTIONS_BKGRD_COLOR 0xF0F0F0
!define INSTALL_BLURB_TEXT_COLOR 0x666666
!define INSTALL_PROGRESS_TEXT_COLOR_NORMAL 0x666666
!define INSTALL_PROGRESS_TEXT_COLOR_FADED 0x999999

Двоичные данные
browser/branding/unofficial/appname.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 12 KiB

После

Ширина:  |  Высота:  |  Размер: 11 KiB

Двоичные данные
browser/branding/unofficial/bgintro.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 666 KiB

После

Ширина:  |  Высота:  |  Размер: 666 KiB

Просмотреть файл

@ -19,3 +19,26 @@
# The installer's certificate name and issuer expected by the stub installer
!define CertNameDownload "Mozilla Corporation"
!define CertIssuerDownload "Thawte Code Signing CA - G2"
# Dialog units are used so the UI displays correctly with the system's DPI
# settings.
# The dialog units for the bitmap's dimensions should match exactly with the
# bitmap's width and height in pixels.
!define APPNAME_BMP_WIDTH_DU 159u
!define APPNAME_BMP_HEIGHT_DU 26u
!define INTRO_BLURB_WIDTH_DU "230u"
!define INTRO_BLURB_EDGE_DU "198u"
!define INTRO_BLURB_LTR_TOP_DU "16u"
!define INTRO_BLURB_RTL_TOP_DU "11u"
# UI Colors that can be customized for each channel
!define FOOTER_CONTROL_TEXT_COLOR_NORMAL 0x000000
!define FOOTER_CONTROL_TEXT_COLOR_FADED 0x999999
!define FOOTER_BKGRD_COLOR 0xFFFFFF
!define INTRO_BLURB_TEXT_COLOR 0xFFFFFF
!define OPTIONS_TEXT_COLOR_NORMAL 0xFFFFFF
!define OPTIONS_TEXT_COLOR_FADED 0xA1AAB3
!define OPTIONS_BKGRD_COLOR 0x0F1B26
!define INSTALL_BLURB_TEXT_COLOR 0xFFFFFF
!define INSTALL_PROGRESS_TEXT_COLOR_NORMAL 0xFFFFFF
!define INSTALL_PROGRESS_TEXT_COLOR_FADED 0xA1AAB3

Двоичные данные
browser/branding/unofficial/clock.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/unofficial/particles.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/unofficial/pencil-rtl.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Двоичные данные
browser/branding/unofficial/pencil.bmp

Двоичный файл не отображается.

До

Ширина:  |  Высота:  |  Размер: 8.8 KiB

После

Ширина:  |  Высота:  |  Размер: 8.8 KiB

Просмотреть файл

@ -44,6 +44,9 @@ XPCOMUtils.defineLazyModuleGetter(this, "BrowserNewTabPreloader",
XPCOMUtils.defineLazyModuleGetter(this, "PdfJs",
"resource://pdf.js/PdfJs.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "webrtcUI",
"resource:///modules/webrtcUI.jsm");
const PREF_PLUGINS_NOTIFYUSER = "plugins.update.notifyUser";
const PREF_PLUGINS_UPDATEURL = "plugins.update.url";
@ -320,6 +323,7 @@ BrowserGlue.prototype = {
UserAgentOverrides.uninit();
webappsUI.uninit();
SignInToWebsiteUX.uninit();
webrtcUI.uninit();
},
_onAppDefaults: function BG__onAppDefaults() {
@ -351,6 +355,7 @@ BrowserGlue.prototype = {
BrowserNewTabPreloader.init();
SignInToWebsiteUX.init();
PdfJs.init();
webrtcUI.init();
Services.obs.notifyObservers(null, "browser-ui-startup-complete", "");
},

Просмотреть файл

@ -49,6 +49,8 @@ function test() {
is(getTabNumbers(aGroup), "0,6,2,3,5,1", "Validate tab positions in test 3.");
is(aCW.GroupItems.groupItems.length, 3, "Validate group count in test 3.");
// This test is disabled because it is fragile -- see bug 797975
if (false) {
// Test 4: Move the fifth tab back into the group, on the second row.
waitForTransition(tab, function() {
moveTabInGroup(tab, 4, aGroup, aCW);
@ -56,6 +58,9 @@ function test() {
is(aCW.GroupItems.groupItems.length, 2, "Validate group count in test 4.");
closeGroupItem(aGroup, function() { hideTabView(finish) });
});
} else {
closeGroupItem(aGroup, function() { hideTabView(finish) });
}
}
function createGroup(win) {

Просмотреть файл

@ -1,6 +1,6 @@
[
{
"clang_version": "r162360"
"clang_version": "r163716"
},
{
"size": 47,
@ -9,8 +9,8 @@
"filename": "setup.sh"
},
{
"size": 63855729,
"digest": "77b3693b37660ac3785ab4aeb77cb388ac6cd5aebe329b4b754e4bc8518d2b72af20c0cf59f671efd6b37cbc19179b96df818b8fdf665912c9ae58966633b96c",
"size": 61047821,
"digest": "964837fd04d0ff7b0c01ca6ed8f3716256b9334e0d1200a7a06235bf837a75d41371d389b401cc15744ff509ecf96f31bdc0e679a0b3a6be93090673d5432ba4",
"algorithm": "sha512",
"filename": "clang.tar.bz2"
}

Просмотреть файл

@ -1,6 +1,6 @@
[
{
"clang_version": "r162360"
"clang_version": "r163716"
},
{
"size": 47,
@ -9,8 +9,8 @@
"filename": "setup.sh"
},
{
"size": 61312067,
"digest": "8685d44ae06d16c8318cff25e064247105de84bdff74bddb6936d2277d4995393174e10f0eaf9fd65e12086071e23854e0b2cbb09385ef0ee40d0ef5e12e30ed",
"size": 61004559,
"digest": "32d995275a00ed3f7ea79a4057c84108b2e1ebf13e89f05c96893b0e3602dc4891d962d8a61dbe5a395beb0fa6932ab90d5d3fa7eef7b95c092a7974e4cbd625",
"algorithm": "sha512",
"filename": "clang.tar.bz2"
}

Просмотреть файл

@ -1,6 +1,6 @@
[
{
"clang_version": "r162360"
"clang_version": "r163716"
},
{
"size": 47,
@ -9,8 +9,8 @@
"filename": "setup.sh"
},
{
"size": 54372252,
"digest": "e4b198da311aa851b14a65a392b1f429d0df942bd6167887e389c89fbdbd46c00d3d09f88923f8b2bf6c41c3ab9ea87de54473deb3b6b0a71eb4146d483ba035",
"size": 54033946,
"digest": "50eb6fa636403f444bab10aee2370f1ac624a1e0105566639c7c266e784dbc6e4cd3901bbd11f53c4c63b2a6d2d07a603b3d9c333f5049bdc7a816b7d225631b",
"algorithm": "sha512",
"filename": "clang.tar.bz2"
}

Просмотреть файл

@ -1,6 +1,6 @@
[
{
"clang_version": "r162360"
"clang_version": "r163716"
},
{
"size": 47,
@ -9,8 +9,8 @@
"filename": "setup.sh"
},
{
"size": 54372252,
"digest": "e4b198da311aa851b14a65a392b1f429d0df942bd6167887e389c89fbdbd46c00d3d09f88923f8b2bf6c41c3ab9ea87de54473deb3b6b0a71eb4146d483ba035",
"size": 54033946,
"digest": "50eb6fa636403f444bab10aee2370f1ac624a1e0105566639c7c266e784dbc6e4cd3901bbd11f53c4c63b2a6d2d07a603b3d9c333f5049bdc7a816b7d225631b",
"algorithm": "sha512",
"filename": "clang.tar.bz2"
}

Просмотреть файл

@ -247,7 +247,7 @@ function test()
let check = bkp.querySelector("checkbox");
is(bkp.id, id,
"Breakpoint element " + id + " found succesfully.");
"Breakpoint element " + id + " found successfully.");
is(info.getAttribute("value"), getExpectedBreakpointInfo(this.line),
"The expected information wasn't found in the breakpoint element.");
is(text.getAttribute("value"), getExpectedLineText(this.line).trim(),

Просмотреть файл

@ -152,7 +152,7 @@ function testNext() {
pos++;
if (pos < TESTS.length) {
waitForSuccess({
name: "test #" + pos + " succesful finish",
name: "test #" + pos + " successful finish",
validatorFn: function()
{
return foundCategory && foundText && pageLoaded && pageError;

Просмотреть файл

@ -215,7 +215,22 @@ ChromeActions.prototype = {
var frontWindow = Cc['@mozilla.org/embedcomp/window-watcher;1'].
getService(Ci.nsIWindowWatcher).activeWindow;
NetUtil.asyncFetch(blobUri, function(aInputStream, aResult) {
let docIsPrivate = false;
try {
docIsPrivate = this.domWindow
.QueryInterface(Ci.nsIInterfaceRequestor)
.getInterface(Ci.nsIWebNavigation)
.QueryInterface(Ci.nsILoadContext)
.usePrivateBrowsing;
} catch (x) {
}
let netChannel = NetUtil.newChannel(blobUri);
if ('nsIPrivateBrowsingChannel' in Ci &&
netChannel instanceof Ci.nsIPrivateBrowsingChannel) {
netChannel.setPrivate(docIsPrivate);
}
NetUtil.asyncFetch(netChannel, function(aInputStream, aResult) {
if (!Components.isSuccessCode(aResult)) {
if (sendResponse)
sendResponse(true);
@ -228,6 +243,10 @@ ChromeActions.prototype = {
channel.setURI(originalUri);
channel.contentStream = aInputStream;
channel.QueryInterface(Ci.nsIChannel);
if ('nsIPrivateBrowsingChannel' in Ci &&
channel instanceof Ci.nsIPrivateBrowsingChannel) {
channel.setPrivate(docIsPrivate);
}
var listener = {
extListener: null,

Просмотреть файл

@ -76,19 +76,16 @@ VIAddVersionKey "ProductVersion" "${AppVersion}"
# Comments is not used but left below commented out for future reference
# VIAddVersionKey "Comments" "Comments"
!define TO_BE_DELETED "to_be_deleted"
# It isn't possible to get the size of the installation prior to downloading
# so the stub installer uses an estimate.
!define APPROXIMATE_REQUIRED_SPACE_MB "42.2"
# UI colors
!define BOTTOM_BKGRD_COLOR 0xFFFFFF
!define OPTIONS_BKGRD_COLOR 0xF0F0F0
!define CONTROL_TEXT_COLOR 0x000000
!define BLURB_TEXT_COLOR 0x666666
!define FADED_TEXT_COLOR 0x999999
# Control positions in Dialog Units
!define OPTIONS_ITEM_LEFT_DU 90u
!define OPTIONS_SUBITEM_LEFT_DU 119u
# Control positions in Dialog Units so they are placed correctly with
# non-default DPI settings
!define OPTIONS_ITEM_EDGE_DU 90u
!define OPTIONS_ITEM_WIDTH_DU 356u
!define OPTIONS_SUBITEM_EDGE_DU 119u
!define OPTIONS_SUBITEM_WIDTH_DU 327u
!define INSTALL_BLURB_TOP_DU 78u
!define APPNAME_BMP_EDGE_DU 19u
!define APPNAME_BMP_TOP_DU 12u

Просмотреть файл

@ -222,6 +222,8 @@ Section "-Application" APP_IDX
DetailPrint $(STATUS_INSTALL_APP)
SetDetailsPrint none
RmDir /r /REBOOTOK "$INSTDIR\${TO_BE_DELETED}"
${LogHeader} "Installing Main Files"
${CopyFilesFromDir} "$EXEDIR\core" "$INSTDIR" \
"$(ERROR_CREATE_DIRECTORY_PREFIX)" \

Просмотреть файл

@ -94,6 +94,8 @@
${RemoveDeprecatedFiles}
RmDir /r /REBOOTOK "$INSTDIR\${TO_BE_DELETED}"
!ifdef MOZ_MAINTENANCE_SERVICE
Call IsUserAdmin
Pop $R0

Просмотреть файл

@ -63,6 +63,7 @@ Var SpaceAvailableBytes
Var InitialInstallDir
Var HandleDownload
Var CanSetAsDefault
Var TmpVal
Var HEIGHT_PX
Var CTL_RIGHT_PX
@ -90,12 +91,14 @@ Var CTL_RIGHT_PX
; Workaround to support different urls for Official and Beta since they share
; the same branding.
!ifdef Official
!ifdef BETA_UPDATE_CHANNEL
!undef URLStubDownload
!define URLStubDownload "http://download.mozilla.org/?product=firefox-beta-latest&os=win&lang=${AB_CD}"
!undef URLManualDownload
!define URLManualDownload "http://download.mozilla.org/?product=firefox-beta-latest&os=win&lang=${AB_CD}"
!endif
!endif
!include "common.nsh"
@ -105,6 +108,7 @@ Var CTL_RIGHT_PX
!insertmacro GetSingleInstallPath
!insertmacro GetTextWidthHeight
!insertmacro IsUserAdmin
!insertmacro OnStubInstallUninstall
!insertmacro SetBrandNameVars
!insertmacro UnloadUAC
@ -297,25 +301,29 @@ Function createIntro
!ifdef ${AB_CD}_rtl
; For RTL align the text with the top of the F in the Firefox bitmap
${NSD_CreateLabel} 170u 12u 258u 76u "${INTRO_BLURB}"
StrCpy $0 "${INTRO_BLURB_RTL_TOP_DU}"
!else
; For LTR align the text with the top of the x in the Firefox bitmap
${NSD_CreateLabel} 170u 20u 258u 76u "${INTRO_BLURB}"
StrCpy $0 "${INTRO_BLURB_LTR_TOP_DU}"
!endif
${NSD_CreateLabel} ${INTRO_BLURB_EDGE_DU} $0 ${INTRO_BLURB_WIDTH_DU} 76u "${INTRO_BLURB}"
Pop $0
SendMessage $0 ${WM_SETFONT} $FontBlurb 0
SetCtlColors $0 ${BLURB_TEXT_COLOR} transparent
SetCtlColors $0 ${INTRO_BLURB_TEXT_COLOR} transparent
${Unless} $Initialized == "true"
SetCtlColors $HWNDPARENT ${CONTROL_TEXT_COLOR} ${BOTTOM_BKGRD_COLOR}
SetCtlColors $HWNDPARENT ${FOOTER_CONTROL_TEXT_COLOR_NORMAL} ${FOOTER_BKGRD_COLOR}
GetDlgItem $0 $HWNDPARENT 10 ; Default browser checkbox
; Set as default is not supported in the installer for Win8 and above so
; only display it on Windows 7 and below
${If} $CanSetAsDefault == "true"
; The uxtheme must be disabled on checkboxes in order to override the
; system font color.
System::Call 'uxtheme::SetWindowTheme(i $0 , w " ", w " ")'
SendMessage $0 ${WM_SETFONT} $FontNormal 0
SendMessage $0 ${WM_SETTEXT} 0 "STR:$(MAKE_DEFAULT)"
SendMessage $0 ${BM_SETCHECK} 1 0
SetCtlColors $0 ${CONTROL_TEXT_COLOR} ${BOTTOM_BKGRD_COLOR}
SetCtlColors $0 ${FOOTER_CONTROL_TEXT_COLOR_NORMAL} ${FOOTER_BKGRD_COLOR}
${Else}
ShowWindow $0 ${SW_HIDE}
${EndIf}
@ -323,7 +331,8 @@ Function createIntro
ShowWindow $0 ${SW_HIDE}
${EndUnless}
${NSD_CreateBitmap} 19u 12u 134u 36u ""
${NSD_CreateBitmap} ${APPNAME_BMP_EDGE_DU} ${APPNAME_BMP_TOP_DU} \
${APPNAME_BMP_WIDTH_DU} ${APPNAME_BMP_HEIGHT_DU} ""
Pop $2
${SetStretchedTransparentImage} $2 $PLUGINSDIR\appname.bmp $0
@ -394,52 +403,64 @@ Function createOptions
StrCpy $ExistingTopDir ""
; There is a bug with setting a transparent background on a checkbox so a
; background image can't used on this page.
; http://sourceforge.net/tracker/index.php?func=detail&aid=1420352&group_id=22049&atid=373085
nsDialogs::Create /NOUNLOAD 1018
Pop $Dialog
; Since the text color for controls is set in this Dialog the foreground and
; background colors of the Dialog must also be hardcoded.
SetCtlColors $Dialog ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
SetCtlColors $Dialog ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
${NSD_CreateLabel} ${OPTIONS_ITEM_LEFT_DU} 18u 100% 12u "$(CREATE_SHORTCUTS)"
${NSD_CreateLabel} ${OPTIONS_ITEM_EDGE_DU} 18u ${OPTIONS_ITEM_WIDTH_DU} \
12u "$(CREATE_SHORTCUTS)"
Pop $0
SetCtlColors $0 ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
SetCtlColors $0 ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $0 ${WM_SETFONT} $FontNormal 0
${If} ${AtLeastWin7}
${NSD_CreateCheckbox} ${OPTIONS_SUBITEM_LEFT_DU} 38u 100% 12u "$(ADD_SC_TASKBAR)"
StrCpy $0 "$(ADD_SC_TASKBAR)"
${Else}
${NSD_CreateCheckbox} ${OPTIONS_SUBITEM_LEFT_DU} 38u 100% 12u "$(ADD_SC_QUICKLAUNCHBAR)"
StrCpy $0 "$(ADD_SC_QUICKLAUNCHBAR)"
${EndIf}
${NSD_CreateCheckbox} ${OPTIONS_SUBITEM_EDGE_DU} 38u \
${OPTIONS_SUBITEM_WIDTH_DU} 12u "$0"
Pop $CheckboxShortcutOnBar
SetCtlColors $CheckboxShortcutOnBar ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
; The uxtheme must be disabled on checkboxes in order to override the system
; font color.
System::Call 'uxtheme::SetWindowTheme(i $CheckboxShortcutOnBar, w " ", w " ")'
SetCtlColors $CheckboxShortcutOnBar ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $CheckboxShortcutOnBar ${WM_SETFONT} $FontNormal 0
${NSD_Check} $CheckboxShortcutOnBar
${NSD_CreateCheckbox} ${OPTIONS_SUBITEM_LEFT_DU} 54u 100% 12u "$(ADD_CheckboxShortcutInStartMenu)"
${NSD_CreateCheckbox} ${OPTIONS_SUBITEM_EDGE_DU} 54u ${OPTIONS_SUBITEM_WIDTH_DU} \
12u "$(ADD_CheckboxShortcutInStartMenu)"
Pop $CheckboxShortcutInStartMenu
SetCtlColors $CheckboxShortcutInStartMenu ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
; The uxtheme must be disabled on checkboxes in order to override the system
; font color.
System::Call 'uxtheme::SetWindowTheme(i $CheckboxShortcutInStartMenu, w " ", w " ")'
SetCtlColors $CheckboxShortcutInStartMenu ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $CheckboxShortcutInStartMenu ${WM_SETFONT} $FontNormal 0
${NSD_Check} $CheckboxShortcutInStartMenu
${NSD_CreateCheckbox} ${OPTIONS_SUBITEM_LEFT_DU} 70u 100% 12u "$(ADD_CheckboxShortcutOnDesktop)"
${NSD_CreateCheckbox} ${OPTIONS_SUBITEM_EDGE_DU} 70u ${OPTIONS_SUBITEM_WIDTH_DU} \
12u "$(ADD_CheckboxShortcutOnDesktop)"
Pop $CheckboxShortcutOnDesktop
SetCtlColors $CheckboxShortcutOnDesktop ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
; The uxtheme must be disabled on checkboxes in order to override the system
; font color.
System::Call 'uxtheme::SetWindowTheme(i $CheckboxShortcutOnDesktop, w " ", w " ")'
SetCtlColors $CheckboxShortcutOnDesktop ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $CheckboxShortcutOnDesktop ${WM_SETFONT} $FontNormal 0
${NSD_Check} $CheckboxShortcutOnDesktop
${NSD_CreateLabel} ${OPTIONS_ITEM_LEFT_DU} 100u 100% 12u "$(DEST_FOLDER)"
${NSD_CreateLabel} ${OPTIONS_ITEM_EDGE_DU} 100u ${OPTIONS_ITEM_WIDTH_DU} \
12u "$(DEST_FOLDER)"
Pop $0
SetCtlColors $0 ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
SetCtlColors $0 ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $0 ${WM_SETFONT} $FontNormal 0
${NSD_CreateDirRequest} ${OPTIONS_SUBITEM_LEFT_DU} 116u 159u 14u "$INSTDIR"
${NSD_CreateDirRequest} ${OPTIONS_SUBITEM_EDGE_DU} 116u 159u 14u "$INSTDIR"
Pop $DirRequest
SetCtlColors $DirRequest ${CONTROL_TEXT_COLOR} ${BOTTOM_BKGRD_COLOR}
SetCtlColors $DirRequest ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $DirRequest ${WM_SETFONT} $FontNormal 0
System::Call shlwapi::SHAutoComplete(i $DirRequest,i ${SHACF_FILESYSTEM})
System::Call shlwapi::SHAutoComplete(i $DirRequest, i ${SHACF_FILESYSTEM})
${NSD_OnChange} $DirRequest OnChange_DirRequest
!ifdef ${AB_CD}_rtl
@ -453,6 +474,7 @@ Function createOptions
${NSD_CreateBrowseButton} 280u 116u 50u 14u "$(BROWSE_BUTTON)"
Pop $ButtonBrowse
SetCtlColors $ButtonBrowse "" ${OPTIONS_BKGRD_COLOR}
${NSD_OnClick} $ButtonBrowse OnClick_ButtonBrowse
; Get the number of pixels from the left of the Dialog to the right side of
@ -471,15 +493,15 @@ Function createOptions
IntOp $0 $0 + 8 ; Add padding to the control's width
; Make both controls the same width as the widest control
${NSD_CreateLabelCenter} ${OPTIONS_SUBITEM_LEFT_DU} 134u $0 $HEIGHT_PX "$(SPACE_REQUIRED)"
${NSD_CreateLabelCenter} ${OPTIONS_SUBITEM_EDGE_DU} 134u $0 $HEIGHT_PX "$(SPACE_REQUIRED)"
Pop $5
SetCtlColors $5 ${BLURB_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
SetCtlColors $5 ${OPTIONS_TEXT_COLOR_FADED} ${OPTIONS_BKGRD_COLOR}
SendMessage $5 ${WM_SETFONT} $FontItalic 0
IntOp $2 $2 + 8 ; Add padding to the control's width
${NSD_CreateLabelCenter} ${OPTIONS_SUBITEM_LEFT_DU} 145u $2 $HEIGHT_PX "$(SPACE_AVAILABLE)"
${NSD_CreateLabelCenter} ${OPTIONS_SUBITEM_EDGE_DU} 145u $2 $HEIGHT_PX "$(SPACE_AVAILABLE)"
Pop $6
SetCtlColors $6 ${BLURB_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
SetCtlColors $6 ${OPTIONS_TEXT_COLOR_FADED} ${OPTIONS_BKGRD_COLOR}
SendMessage $6 ${WM_SETFONT} $FontItalic 0
; Use the widest label for aligning the labels next to them
@ -491,16 +513,17 @@ Function createOptions
IntOp $CTL_RIGHT_PX $CTL_RIGHT_PX + 6
${NSD_CreateLabel} $CTL_RIGHT_PX 134u 100% $HEIGHT_PX "${APPROXIMATE_REQUIRED_SPACE_MB} $(MEGA)$(BYTE)"
${NSD_CreateLabel} $CTL_RIGHT_PX 134u 100% $HEIGHT_PX \
"${APPROXIMATE_REQUIRED_SPACE_MB} $(MEGA)$(BYTE)"
Pop $7
SetCtlColors $7 ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
SetCtlColors $7 ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $7 ${WM_SETFONT} $FontNormal 0
; Create the free space label with an empty string and update it by calling
; UpdateFreeSpaceLabel
${NSD_CreateLabel} $CTL_RIGHT_PX 145u 100% $HEIGHT_PX " "
Pop $LabelFreeSpace
SetCtlColors $LabelFreeSpace ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
SetCtlColors $LabelFreeSpace ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $LabelFreeSpace ${WM_SETFONT} $FontNormal 0
Call UpdateFreeSpaceLabel
@ -522,9 +545,11 @@ Function createOptions
ClearErrors
ReadRegStr $0 HKLM "SYSTEM\CurrentControlSet\services\MozillaMaintenance" "ImagePath"
${If} ${Errors}
${NSD_CreateCheckbox} ${OPTIONS_ITEM_LEFT_DU} 175u 100% 12u "$(INSTALL_MAINT_SERVICE)"
${NSD_CreateCheckbox} ${OPTIONS_ITEM_EDGE_DU} 175u ${OPTIONS_ITEM_WIDTH_DU} \
12u "$(INSTALL_MAINT_SERVICE)"
Pop $CheckboxInstallMaintSvc
SetCtlColors $CheckboxInstallMaintSvc ${CONTROL_TEXT_COLOR} ${OPTIONS_BKGRD_COLOR}
System::Call 'uxtheme::SetWindowTheme(i $CheckboxInstallMaintSvc, w " ", w " ")'
SetCtlColors $CheckboxInstallMaintSvc ${OPTIONS_TEXT_COLOR_NORMAL} ${OPTIONS_BKGRD_COLOR}
SendMessage $CheckboxInstallMaintSvc ${WM_SETFONT} $FontNormal 0
${NSD_Check} $CheckboxInstallMaintSvc
${EndIf}
@ -625,7 +650,7 @@ Function createInstall
${NSD_CreateLabel} $R1 ${INSTALL_BLURB_TOP_DU} $5 $6 "${INSTALL_BLURB1}"
Pop $LabelBlurb1
SendMessage $LabelBlurb1 ${WM_SETFONT} $FontBlurb 0
SetCtlColors $LabelBlurb1 ${BLURB_TEXT_COLOR} transparent
SetCtlColors $LabelBlurb1 ${INSTALL_BLURB_TEXT_COLOR} transparent
${GetTextWidthHeight} "${INSTALL_BLURB2}" $FontBlurb $R0 $5 $6
IntOp $R1 $1 + $3
@ -640,7 +665,7 @@ Function createInstall
${NSD_CreateLabel} $R1 ${INSTALL_BLURB_TOP_DU} $5 $6 "${INSTALL_BLURB2}"
Pop $LabelBlurb2
SendMessage $LabelBlurb2 ${WM_SETFONT} $FontBlurb 0
SetCtlColors $LabelBlurb2 ${BLURB_TEXT_COLOR} transparent
SetCtlColors $LabelBlurb2 ${INSTALL_BLURB_TEXT_COLOR} transparent
ShowWindow $BitmapBlurb2 ${SW_HIDE}
ShowWindow $LabelBlurb2 ${SW_HIDE}
@ -657,7 +682,7 @@ Function createInstall
${NSD_CreateLabel} $R1 ${INSTALL_BLURB_TOP_DU} $5 $6 "${INSTALL_BLURB3}"
Pop $LabelBlurb3
SendMessage $LabelBlurb3 ${WM_SETFONT} $FontBlurb 0
SetCtlColors $LabelBlurb3 ${BLURB_TEXT_COLOR} transparent
SetCtlColors $LabelBlurb3 ${INSTALL_BLURB_TEXT_COLOR} transparent
ShowWindow $BitmapBlurb3 ${SW_HIDE}
ShowWindow $LabelBlurb3 ${SW_HIDE}
@ -667,23 +692,23 @@ Function createInstall
${NSD_CreateLabelCenter} 103u 180u 157u 20u "$(DOWNLOADING_IN_PROGRESS)"
Pop $LabelDownloadingInProgress
SendMessage $LabelDownloadingInProgress ${WM_SETFONT} $FontNormal 0
SetCtlColors $LabelDownloadingInProgress ${BLURB_TEXT_COLOR} transparent
SetCtlColors $LabelDownloadingInProgress ${INSTALL_PROGRESS_TEXT_COLOR_NORMAL} transparent
${NSD_CreateLabelCenter} 103u 180u 157u 20u "$(DOWNLOADING_DONE)"
Pop $LabelDownloadingDown
SendMessage $LabelDownloadingDown ${WM_SETFONT} $FontItalic 0
SetCtlColors $LabelDownloadingDown ${FADED_TEXT_COLOR} transparent
SetCtlColors $LabelDownloadingDown ${INSTALL_PROGRESS_TEXT_COLOR_FADED} transparent
ShowWindow $LabelDownloadingDown ${SW_HIDE}
${NSD_CreateLabelCenter} 260uu 180u 84u 20u "$(INSTALLING_TO_BE_DONE)"
Pop $LabelInstallingToBeDone
SendMessage $LabelInstallingToBeDone ${WM_SETFONT} $FontItalic 0
SetCtlColors $LabelInstallingToBeDone ${FADED_TEXT_COLOR} transparent
SetCtlColors $LabelInstallingToBeDone ${INSTALL_PROGRESS_TEXT_COLOR_FADED} transparent
${NSD_CreateLabelCenter} 260uu 180u 84u 20u "$(INSTALLING_IN_PROGRESS)"
Pop $LabelInstallingInProgress
SendMessage $LabelInstallingInProgress ${WM_SETFONT} $FontNormal 0
SetCtlColors $LabelInstallingInProgress ${BLURB_TEXT_COLOR} transparent
SetCtlColors $LabelInstallingInProgress ${INSTALL_PROGRESS_TEXT_COLOR_NORMAL} transparent
ShowWindow $LabelInstallingInProgress ${SW_HIDE}
${NSD_CreateProgressBar} 103u 166u 157u 9u ""
@ -696,7 +721,8 @@ Function createInstall
${NSD_AddStyle} $ProgressbarInstall ${PBS_MARQUEE}
SendMessage $ProgressbarInstall ${PBM_SETMARQUEE} 0 10 ; start=1|stop=0 interval(ms)=+N
${NSD_CreateBitmap} 19u 12u 134u 36u ""
${NSD_CreateBitmap} ${APPNAME_BMP_EDGE_DU} ${APPNAME_BMP_TOP_DU} \
${APPNAME_BMP_WIDTH_DU} ${APPNAME_BMP_HEIGHT_DU} ""
Pop $2
${SetStretchedTransparentImage} $2 $PLUGINSDIR\appname.bmp $0
@ -731,7 +757,7 @@ Function createInstall
GetDlgItem $0 $HWNDPARENT 11
SendMessage $0 ${WM_SETTEXT} 0 "STR:$(ONE_MOMENT)"
SendMessage $0 ${WM_SETFONT} $FontNormal 0
SetCtlColors $0 ${BLURB_TEXT_COLOR} ${BOTTOM_BKGRD_COLOR}
SetCtlColors $0 ${FOOTER_CONTROL_TEXT_COLOR_FADED} ${FOOTER_BKGRD_COLOR}
ShowWindow $0 ${SW_SHOW}
StrCpy $DownloadReset "false"
@ -836,7 +862,7 @@ Function OnDownload
; Open a handle to prevent modification of the full installer
StrCpy $R9 "${INVALID_HANDLE_VALUE}"
System::Call 'kernel32::CreateFileW(t "$PLUGINSDIR\download.exe", \
System::Call 'kernel32::CreateFileW(w "$PLUGINSDIR\download.exe", \
i ${GENERIC_READ}, \
i ${FILE_SHARE_READ}, i 0, \
i ${OPEN_EXISTING}, i 0, i 0) i .R9'
@ -901,21 +927,7 @@ Function OnDownload
WriteIniStr "$0" "TASKBAR" "Migrated" "true"
${EndIf}
${If} ${FileExists} "$INSTDIR\${FileMainEXE}"
; Move files that are check in shared.nsh for in use out of the way
; so installing silently will just succeed.
CreateDirectory "$INSTDIR\${TO_BE_DELETED}"
Rename "$INSTDIR\${FileMainEXE}" "$INSTDIR\${TO_BE_DELETED}\${FileMainEXE}"
Rename "$INSTDIR\updater.exe" "$INSTDIR\${TO_BE_DELETED}\updater.exe"
Rename "$INSTDIR\crashreporter.exe" "$INSTDIR\${TO_BE_DELETED}\crashreporter.exe"
Rename "$INSTDIR\xpcom.dll" "$INSTDIR\${TO_BE_DELETED}\xpcom.dll"
Rename "$INSTDIR\mozsqlite3.dll" "$INSTDIR\${TO_BE_DELETED}\mozsqlite3.dll"
Rename "$INSTDIR\nssdbm3.dll" "$INSTDIR\${TO_BE_DELETED}\nssdbm3.dll"
Rename "$INSTDIR\nspr4.dll" "$INSTDIR\${TO_BE_DELETED}\nspr4.dll"
Rename "$INSTDIR\nssckbi.dll" "$INSTDIR\${TO_BE_DELETED}\nssckbi.dll"
Rename "$INSTDIR\freebl3.dll" "$INSTDIR\${TO_BE_DELETED}\freebl3.dll"
Rename "$INSTDIR\AccessibleMarshal.dll" "$INSTDIR\${TO_BE_DELETED}\AccessibleMarshal.dll"
${EndIf}
${OnStubInstallUninstall}
Exec "$\"$PLUGINSDIR\download.exe$\" /INI=$PLUGINSDIR\${CONFIG_INI}"
; Close the handle that prevents modification of the full installer
@ -950,9 +962,6 @@ Function StartInstall
Delete "$INSTDIR\uninstall\uninstall.tmp"
Delete "$PLUGINSDIR\download.exe"
Delete "$PLUGINSDIR\${CONFIG_INI}"
${If} ${FileExists} "$INSTDIR\${TO_BE_DELETED}"
RmDir /r /REBOOTOK "$INSTDIR\${TO_BE_DELETED}"
${EndIf}
${If} "$CheckboxSetAsDefault" == "1"
${GetParameters} $0
@ -1072,7 +1081,7 @@ FunctionEnd
Function OnChange_DirRequest
Pop $0
System::Call `user32::GetWindowTextW(i $DirRequest, t .r0, i ${NSIS_MAX_STRLEN})`
System::Call 'user32::GetWindowTextW(i $DirRequest, w .r0, i ${NSIS_MAX_STRLEN})'
StrCpy $INSTDIR $0
Call UpdateFreeSpaceLabel
FunctionEnd
@ -1097,7 +1106,7 @@ Function OnClick_ButtonBrowse
${If} $0 != ""
StrCpy $INSTDIR "$0"
system::Call `user32::SetWindowTextW(i $DirRequest, t "$INSTDIR")`
system::Call 'user32::SetWindowTextW(i $DirRequest, w "$INSTDIR")'
${EndIf}
FunctionEnd

Просмотреть файл

@ -414,6 +414,8 @@ Section "Uninstall"
RmDir "$INSTDIR\webapprt\components"
RmDir "$INSTDIR\webapprt"
RmDir /r /REBOOTOK "$INSTDIR\${TO_BE_DELETED}"
; Remove the installation directory if it is empty
${RemoveDir} "$INSTDIR"

Просмотреть файл

@ -423,3 +423,17 @@ identity.next.accessKey = n
identity.loggedIn.description = Signed in as: %S
identity.loggedIn.signOut.label = Sign Out
identity.loggedIn.signOut.accessKey = O
# LOCALIZATION NOTE (getUserMedia.shareCamera.message, getUserMedia.shareMicrophone.message, getUserMedia.shareCameraAndMicrophone.message): %S is the website origin (e.g. www.mozilla.org)
# LOCALIZATION NOTE (getUserMedia.shareMicrophone.message, getUserMedia.shareSpecificMicrophone.label): %S is the website origin (e.g. www.mozilla.org)
getUserMedia.shareCamera.message = Would you like to share your camera with %S?
getUserMedia.shareCamera.label = Share Camera
getUserMedia.shareCamera.accesskey = S
getUserMedia.shareSpecificCamera.label = Share Camera: %S
getUserMedia.shareMicrophone.message = Would you like to share your microphone with %S?
getUserMedia.shareMicrophone.label = Share Microphone
getUserMedia.shareMicrophone.accesskey = S
getUserMedia.shareSpecificMicrophone.label = Share Microphone: %S
getUserMedia.shareCameraAndMicrophone.message = Would you like to share your camera and microphone with %S?
getUserMedia.shareCameraAndMicrophone.label = Share Camera and Microphone
getUserMedia.shareCameraAndMicrophone.accesskey = S

Просмотреть файл

@ -24,6 +24,7 @@ EXTRA_JS_MODULES = \
TelemetryTimestamps.jsm \
Social.jsm \
webappsUI.jsm \
webrtcUI.jsm \
$(NULL)
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)

Просмотреть файл

@ -0,0 +1,123 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
"use strict";
let EXPORTED_SYMBOLS = ["webrtcUI"];
const Cu = Components.utils;
const Ci = Components.interfaces;
Cu.import("resource://gre/modules/Services.jsm");
let webrtcUI = {
init: function () {
Services.obs.addObserver(handleRequest, "getUserMedia:request", false);
},
uninit: function () {
Services.obs.removeObserver(handleRequest, "getUserMedia:request");
}
}
function handleRequest(aSubject, aTopic, aData) {
let {windowID: windowID, callID: callID} = JSON.parse(aData);
let someWindow = Services.wm.getMostRecentWindow(null);
let contentWindow = someWindow.QueryInterface(Ci.nsIInterfaceRequestor)
.getInterface(Ci.nsIDOMWindowUtils)
.getOuterWindowWithId(windowID);
let browser = contentWindow.QueryInterface(Ci.nsIInterfaceRequestor)
.getInterface(Ci.nsIWebNavigation)
.QueryInterface(Ci.nsIDocShell)
.chromeEventHandler;
let params = aSubject.QueryInterface(Ci.nsIMediaStreamOptions);
browser.ownerDocument.defaultView.navigator.mozGetUserMediaDevices(
function (devices) {
prompt(browser, callID, params.audio, params.video, devices);
},
function (error) {
Cu.reportError(error);
}
);
}
function prompt(aBrowser, aCallID, aAudioRequested, aVideoRequested, aDevices) {
let audioDevices = [];
let videoDevices = [];
for (let device of aDevices) {
device = device.QueryInterface(Ci.nsIMediaDevice);
switch (device.type) {
case "audio":
if (aAudioRequested)
audioDevices.push(device);
break;
case "video":
if (aVideoRequested)
videoDevices.push(device);
break;
}
}
let requestType;
if (audioDevices.length && videoDevices.length)
requestType = "shareCameraAndMicrophone";
else if (audioDevices.length)
requestType = "shareMicrophone";
else if (videoDevices.length)
requestType = "shareCamera";
else
return;
let host = aBrowser.contentDocument.documentURIObject.asciiHost;
let chromeWin = aBrowser.ownerDocument.defaultView;
let stringBundle = chromeWin.gNavigatorBundle;
let message = stringBundle.getFormattedString("getUserMedia." + requestType + ".message",
[ host ]);
let responseSent = false;
let mainAction = {
label: stringBundle.getString("getUserMedia." + requestType + ".label"),
accessKey: stringBundle.getString("getUserMedia." + requestType + ".accesskey"),
callback: function () {
Services.obs.notifyObservers(null, "getUserMedia:response:allow", aCallID);
responseSent = true;
}
};
let secondaryActions = [];
let selectableDevices = videoDevices.length ? videoDevices : audioDevices;
if (selectableDevices.length > 1) {
let selectableDeviceNumber = 0;
for (let device of selectableDevices) {
selectableDeviceNumber++;
secondaryActions.push({
label: stringBundle.getFormattedString(
device.type == "audio" ?
"getUserMedia.shareSpecificMicrophone.label" :
"getUserMedia.shareSpecificCamera.label",
[ device.name ]),
accessKey: selectableDeviceNumber,
callback: function () {
Services.obs.notifyObservers(device, "getUserMedia:response:allow", aCallID);
responseSent = true;
}
});
}
}
let options = {
removeOnDismissal: true,
eventCallback: function (aType) {
if (!responseSent && aType == "removed")
Services.obs.notifyObservers(null, "getUserMedia:response:deny", aCallID);
}
};
chromeWin.PopupNotifications.show(aBrowser, "webRTC-shareDevices", message,
"webRTC-notification-icon", mainAction,
secondaryActions, options);
}

Просмотреть файл

@ -1199,6 +1199,10 @@ toolbar[iconsize="small"] #feed-button {
list-style-image: url(chrome://browser/skin/webapps-64.png);
}
.popup-notification-icon[popupid="webRTC-shareDevices"] {
list-style-image: url(chrome://browser/skin/webRTC-shareDevice-64.png);
}
/* Notification icon box */
#notification-popup-box {
position: relative;
@ -1266,6 +1270,10 @@ toolbar[iconsize="small"] #feed-button {
list-style-image: url(chrome://mozapps/skin/plugins/pluginGeneric-16.png);
}
#webRTC-notification-icon {
list-style-image: url(chrome://browser/skin/webRTC-shareDevice-16.png);
}
#treecolAutoCompleteImage {
max-width : 36px;
}
@ -2637,9 +2645,10 @@ html|*#gcli-output-frame {
padding: 0;
}
.social-notification-icon-stack > image {
.social-notification-icon-image {
margin: 5px 3px;
max-height: 16px;
width: 16px;
height: 16px;
}
.social-notification-icon-hbox {

Просмотреть файл

@ -5,9 +5,9 @@
browser.jar:
% skin browser classic/1.0 %skin/classic/browser/
% override chrome://global/skin/icons/warning-16.png moz-icon://stock/gtk-dialog-warning?size=menu
skin/classic/browser/sanitizeDialog.css (sanitizeDialog.css)
* skin/classic/browser/aboutPrivateBrowsing.css (aboutPrivateBrowsing.css)
* skin/classic/browser/aboutSessionRestore.css (aboutSessionRestore.css)
skin/classic/browser/sanitizeDialog.css
* skin/classic/browser/aboutPrivateBrowsing.css
* skin/classic/browser/aboutSessionRestore.css
skin/classic/browser/aboutSessionRestore-window-icon.png
skin/classic/browser/aboutCertError.css
skin/classic/browser/aboutCertError_sectionCollapsed.png
@ -18,8 +18,8 @@ browser.jar:
skin/classic/browser/aboutSyncTabs.css
#endif
skin/classic/browser/actionicon-tab.png
* skin/classic/browser/browser.css (browser.css)
* skin/classic/browser/engineManager.css (engineManager.css)
* skin/classic/browser/browser.css
* skin/classic/browser/engineManager.css
skin/classic/browser/Geolocation-16.png
skin/classic/browser/Geolocation-64.png
skin/classic/browser/Go-arrow.png
@ -36,13 +36,15 @@ browser.jar:
skin/classic/browser/page-livemarks.png
skin/classic/browser/Privacy-16.png
skin/classic/browser/Privacy-48.png
skin/classic/browser/searchbar.css (searchbar.css)
skin/classic/browser/searchbar.css
skin/classic/browser/Secure.png
skin/classic/browser/Security-broken.png
skin/classic/browser/setDesktopBackground.css
skin/classic/browser/Toolbar.png
skin/classic/browser/Toolbar-small.png
skin/classic/browser/urlbar-arrow.png
skin/classic/browser/webRTC-shareDevice-16.png
skin/classic/browser/webRTC-shareDevice-64.png
skin/classic/browser/downloads/buttons.png (downloads/buttons.png)
skin/classic/browser/downloads/download-glow.png (downloads/download-glow.png)
skin/classic/browser/downloads/download-notification.png (downloads/download-notification.png)

Двоичные данные
browser/themes/gnomestripe/webRTC-shareDevice-16.png Normal file

Двоичный файл не отображается.

После

Ширина:  |  Высота:  |  Размер: 854 B

Двоичные данные
browser/themes/gnomestripe/webRTC-shareDevice-64.png Normal file

Двоичный файл не отображается.

После

Ширина:  |  Высота:  |  Размер: 4.1 KiB

Просмотреть файл

@ -3027,6 +3027,10 @@ toolbarbutton.chevron > .toolbarbutton-menu-dropmarker {
list-style-image: url(chrome://mozapps/skin/plugins/pluginGeneric-16.png);
}
#webRTC-notification-icon {
list-style-image: url(chrome://browser/skin/webRTC-shareDevice-16.png);
}
.popup-notification-icon {
width: 64px;
height: 64px;
@ -3107,6 +3111,10 @@ toolbarbutton.chevron > .toolbarbutton-menu-dropmarker {
list-style-image: url(chrome://browser/skin/webapps-64.png);
}
.popup-notification-icon[popupid="webRTC-shareDevices"] {
list-style-image: url(chrome://browser/skin/webRTC-shareDevice-64.png);
}
/* Popup Buttons */
#identity-popup-more-info-button {
@hudButton@
@ -4050,10 +4058,6 @@ html|*#gcli-output-frame {
padding: 0;
}
.social-notification-icon-stack > image {
max-height: 16px;
}
.social-notification-icon-hbox {
padding: 0;
}
@ -4081,10 +4085,9 @@ html|*#gcli-output-frame {
}
}
@media (min-resolution: 2dppx) {
.social-notification-icon-image {
list-style-image: url("chrome://mozapps/skin/places/defaultFavicon@2x.png");
}
.social-notification-icon-image {
width: 16px;
height: 16px;
}
/* === end of social toolbar button === */

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше