mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Merge from tracemonkey to jsdbg2.
This commit is contained in:
commit
03415943ee
203
accessible/src/atk/AtkSocketAccessible.cpp
Normal file
203
accessible/src/atk/AtkSocketAccessible.cpp
Normal file
@ -0,0 +1,203 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2:
|
||||
*/
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
* The contents of this file are subject to the Mozilla Public License Version
|
||||
* 1.1 (the "License"); you may not use this file except in compliance with
|
||||
* the License. You may obtain a copy of the License at
|
||||
* http://www.mozilla.org/MPL/
|
||||
*
|
||||
* Software distributed under the License is distributed on an "AS IS" basis,
|
||||
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
* for the specific language governing rights and limitations under the
|
||||
* License.
|
||||
*
|
||||
* The Original Code is mozilla.org code.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Novell, Inc.
|
||||
* Portions created by the Initial Developer are Copyright (C) 2010
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Brad Taylor <brad@getcoded.net> (original author)
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
* in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
* of those above. If you wish to allow use of your version of this file only
|
||||
* under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
* use your version of this file under the terms of the MPL, indicate your
|
||||
* decision by deleting the provisions above and replace them with the notice
|
||||
* and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
* the provisions above, a recipient may use your version of this file under
|
||||
* the terms of any one of the MPL, the GPL or the LGPL.
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
#include <atk/atk.h>
|
||||
#include "AtkSocketAccessible.h"
|
||||
#include "nsMai.h"
|
||||
#include "nsMaiInterfaceComponent.h"
|
||||
|
||||
void (*AtkSocketAccessible::g_atk_socket_embed) (AtkSocket*, gchar*) = NULL;
|
||||
GType AtkSocketAccessible::g_atk_socket_type = G_TYPE_INVALID;
|
||||
const char* AtkSocketAccessible::sATKSocketEmbedSymbol = "atk_socket_embed";
|
||||
const char* AtkSocketAccessible::sATKSocketGetTypeSymbol = "atk_socket_get_type";
|
||||
|
||||
bool AtkSocketAccessible::gCanEmbed = FALSE;
|
||||
|
||||
/* MaiAtkSocket */
|
||||
|
||||
#define MAI_TYPE_ATK_SOCKET (mai_atk_socket_get_type ())
|
||||
#define MAI_ATK_SOCKET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj),\
|
||||
MAI_TYPE_ATK_SOCKET, MaiAtkSocket))
|
||||
#define MAI_IS_ATK_SOCKET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj),\
|
||||
MAI_TYPE_ATK_SOCKET))
|
||||
#define MAI_ATK_SOCKET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass),\
|
||||
MAI_TYPE_ATK_SOCKET,\
|
||||
MaiAtkSocketClass))
|
||||
#define MAI_IS_ATK_SOCKET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass),\
|
||||
MAI_TYPE_ATK_SOCKET))
|
||||
#define MAI_ATK_SOCKET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj),\
|
||||
MAI_TYPE_ATK_SOCKET,\
|
||||
MaiAtkSocketClass))
|
||||
|
||||
typedef struct _MaiAtkSocket MaiAtkSocket;
|
||||
typedef struct _MaiAtkSocketClass MaiAtkSocketClass;
|
||||
|
||||
struct _MaiAtkSocket
|
||||
{
|
||||
AtkSocket parent;
|
||||
|
||||
nsAccessibleWrap* accWrap;
|
||||
};
|
||||
|
||||
struct _MaiAtkSocketClass
|
||||
{
|
||||
AtkSocketClass parent_class;
|
||||
};
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
GType mai_atk_socket_get_type(void);
|
||||
AtkObject* mai_atk_socket_new(nsAccessibleWrap* aAccWrap);
|
||||
|
||||
void mai_atk_component_iface_init(AtkComponentIface* aIface);
|
||||
AtkObject* mai_atk_socket_ref_accessible_at_point(AtkComponent *aComponent,
|
||||
gint aAccX,
|
||||
gint aAccY,
|
||||
AtkCoordType aCoordType);
|
||||
void mai_atk_socket_get_extents(AtkComponent* aComponent,
|
||||
gint* aAccX,
|
||||
gint* aAccY,
|
||||
gint* aAccWidth,
|
||||
gint* aAccHeight,
|
||||
AtkCoordType aCoordType);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
G_DEFINE_TYPE_EXTENDED(MaiAtkSocket, mai_atk_socket,
|
||||
AtkSocketAccessible::g_atk_socket_type, 0,
|
||||
G_IMPLEMENT_INTERFACE(ATK_TYPE_COMPONENT,
|
||||
mai_atk_component_iface_init))
|
||||
|
||||
void
|
||||
mai_atk_socket_class_init(MaiAtkSocketClass* aAcc)
|
||||
{
|
||||
}
|
||||
|
||||
void
|
||||
mai_atk_socket_init(MaiAtkSocket* aAcc)
|
||||
{
|
||||
}
|
||||
|
||||
AtkObject*
|
||||
mai_atk_socket_new(nsAccessibleWrap* aAccWrap)
|
||||
{
|
||||
NS_ENSURE_TRUE(aAccWrap, NULL);
|
||||
|
||||
MaiAtkSocket* acc = nsnull;
|
||||
acc = static_cast<MaiAtkSocket*>(g_object_new(MAI_TYPE_ATK_SOCKET, NULL));
|
||||
NS_ENSURE_TRUE(acc, NULL);
|
||||
|
||||
acc->accWrap = aAccWrap;
|
||||
return ATK_OBJECT(acc);
|
||||
}
|
||||
|
||||
void
|
||||
mai_atk_component_iface_init(AtkComponentIface* aIface)
|
||||
{
|
||||
NS_ASSERTION(aIface, "Invalid Interface");
|
||||
|
||||
aIface->ref_accessible_at_point = mai_atk_socket_ref_accessible_at_point;
|
||||
aIface->get_extents = mai_atk_socket_get_extents;
|
||||
}
|
||||
|
||||
AtkObject*
|
||||
mai_atk_socket_ref_accessible_at_point(AtkComponent* aComponent,
|
||||
gint aX, gint aY,
|
||||
AtkCoordType aCoordType)
|
||||
{
|
||||
NS_ENSURE_TRUE(MAI_IS_ATK_SOCKET(aComponent), nsnull);
|
||||
|
||||
return refAccessibleAtPointHelper(MAI_ATK_SOCKET(aComponent)->accWrap,
|
||||
aX, aY, aCoordType);
|
||||
}
|
||||
|
||||
void
|
||||
mai_atk_socket_get_extents(AtkComponent* aComponent,
|
||||
gint* aX, gint* aY, gint* aWidth, gint* aHeight,
|
||||
AtkCoordType aCoordType)
|
||||
{
|
||||
*aX = *aY = *aWidth = *aHeight = 0;
|
||||
|
||||
if (!MAI_IS_ATK_SOCKET(aComponent))
|
||||
return;
|
||||
|
||||
getExtentsHelper(MAI_ATK_SOCKET(aComponent)->accWrap,
|
||||
aX, aY, aWidth, aHeight, aCoordType);
|
||||
}
|
||||
|
||||
AtkSocketAccessible::AtkSocketAccessible(nsIContent* aContent,
|
||||
nsIWeakReference* aShell,
|
||||
const nsCString& aPlugId) :
|
||||
nsAccessibleWrap(aContent, aShell)
|
||||
{
|
||||
mAtkObject = mai_atk_socket_new(this);
|
||||
if (!mAtkObject)
|
||||
return;
|
||||
|
||||
// Embeds the children of an AtkPlug, specified by plugId, as the children of
|
||||
// this socket.
|
||||
// Using G_TYPE macros instead of ATK_SOCKET macros to avoid undefined
|
||||
// symbols.
|
||||
if (gCanEmbed && G_TYPE_CHECK_INSTANCE_TYPE(mAtkObject, g_atk_socket_type) &&
|
||||
!aPlugId.IsVoid()) {
|
||||
AtkSocket* accSocket =
|
||||
G_TYPE_CHECK_INSTANCE_CAST(mAtkObject, g_atk_socket_type, AtkSocket);
|
||||
g_atk_socket_embed(accSocket, (gchar*)aPlugId.get());
|
||||
}
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
AtkSocketAccessible::GetNativeInterface(void** aOutAccessible)
|
||||
{
|
||||
*aOutAccessible = mAtkObject;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
void
|
||||
AtkSocketAccessible::Shutdown()
|
||||
{
|
||||
if (mAtkObject) {
|
||||
if (MAI_IS_ATK_SOCKET(mAtkObject))
|
||||
MAI_ATK_SOCKET(mAtkObject)->accWrap = nsnull;
|
||||
g_object_unref(mAtkObject);
|
||||
mAtkObject = nsnull;
|
||||
}
|
||||
nsAccessibleWrap::Shutdown();
|
||||
}
|
@ -1,3 +1,6 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2:
|
||||
*/
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
@ -14,11 +17,12 @@
|
||||
* The Original Code is mozilla.org code.
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Doug Turner <dougt@dougt.org>
|
||||
* Portions created by the Initial Developer are Copyright (C) 2009
|
||||
* Novell, Inc.
|
||||
* Portions created by the Initial Developer are Copyright (C) 2010
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Brad Taylor <brad@getcoded.net> (original author)
|
||||
*
|
||||
* Alternatively, the contents of this file may be used under the terms of
|
||||
* either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
@ -34,26 +38,49 @@
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
#include "nsIDOMEvent.idl"
|
||||
#ifndef _AtkSocketAccessible_H_
|
||||
#define _AtkSocketAccessible_H_
|
||||
|
||||
[scriptable, uuid(1618546a-c176-40a2-9086-2d973acceeb1)]
|
||||
interface nsIDOMOrientationEvent : nsIDOMEvent
|
||||
{
|
||||
void initOrientationEvent(in DOMString eventTypeArg,
|
||||
in boolean canBubbleArg,
|
||||
in boolean cancelableArg,
|
||||
in double x,
|
||||
in double y,
|
||||
in double z);
|
||||
/*
|
||||
* Axis values are between -1 to 1 where 0 is the balance point.
|
||||
*
|
||||
* For example, x = 0 would mean that the device, along the x axis, is parallel to the earth
|
||||
* x decreasing would mean that the device is undergoing a counterclock-wise rotation on the x axis
|
||||
* x increasing would mean that the device is undergoing a clock-wise rotation on the x axis.
|
||||
#include "nsAccessibleWrap.h"
|
||||
|
||||
// This file gets included by nsAccessibilityService.cpp, which can't include
|
||||
// atk.h (or glib.h), so we can't rely on it being included.
|
||||
#ifdef __ATK_H__
|
||||
typedef void (*AtkSocketEmbedType) (AtkSocket*, gchar*);
|
||||
#else
|
||||
typedef void (*AtkSocketEmbedType) (void*, void*);
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Provides a nsAccessibleWrap wrapper around AtkSocket for out-of-process
|
||||
* accessibles.
|
||||
*/
|
||||
class AtkSocketAccessible: public nsAccessibleWrap
|
||||
{
|
||||
public:
|
||||
|
||||
readonly attribute double x;
|
||||
readonly attribute double y;
|
||||
readonly attribute double z;
|
||||
// Soft references to AtkSocket
|
||||
static AtkSocketEmbedType g_atk_socket_embed;
|
||||
#ifdef __ATK_H__
|
||||
static GType g_atk_socket_type;
|
||||
#endif
|
||||
static const char* sATKSocketEmbedSymbol;
|
||||
static const char* sATKSocketGetTypeSymbol;
|
||||
|
||||
/*
|
||||
* True if the current Atk version supports AtkSocket and it was correctly
|
||||
* loaded.
|
||||
*/
|
||||
static bool gCanEmbed;
|
||||
|
||||
AtkSocketAccessible(nsIContent* aContent, nsIWeakReference* aShell,
|
||||
const nsCString& aPlugId);
|
||||
|
||||
// nsAccessNode
|
||||
virtual void Shutdown();
|
||||
|
||||
// nsIAccessible
|
||||
NS_IMETHODIMP GetNativeInterface(void** aOutAccessible);
|
||||
};
|
||||
|
||||
#endif
|
@ -48,6 +48,7 @@ LIBXUL_LIBRARY = 1
|
||||
|
||||
|
||||
CPPSRCS = \
|
||||
AtkSocketAccessible.cpp \
|
||||
nsAccessNodeWrap.cpp \
|
||||
nsAccessibleWrap.cpp \
|
||||
nsDocAccessibleWrap.cpp \
|
||||
@ -68,6 +69,7 @@ CPPSRCS = \
|
||||
$(NULL)
|
||||
|
||||
EXPORTS = \
|
||||
AtkSocketAccessible.h \
|
||||
nsAccessNodeWrap.h \
|
||||
nsARIAGridAccessibleWrap.h \
|
||||
nsAccessibleWrap.h \
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2:
|
||||
*/
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
@ -49,6 +48,7 @@
|
||||
#include "nsIServiceManager.h"
|
||||
#include "nsAutoPtr.h"
|
||||
#include "nsAccessibilityService.h"
|
||||
#include "AtkSocketAccessible.h"
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
#include <atk/atk.h>
|
||||
@ -722,8 +722,23 @@ nsApplicationAccessibleWrap::PreCreate()
|
||||
sATKLib = PR_LoadLibrary(sATKLibName);
|
||||
if (sATKLib) {
|
||||
AtkGetTypeType pfn_atk_hyperlink_impl_get_type = (AtkGetTypeType) PR_FindFunctionSymbol(sATKLib, sATKHyperlinkImplGetTypeSymbol);
|
||||
if (pfn_atk_hyperlink_impl_get_type) {
|
||||
if (pfn_atk_hyperlink_impl_get_type)
|
||||
g_atk_hyperlink_impl_type = pfn_atk_hyperlink_impl_get_type();
|
||||
|
||||
AtkGetTypeType pfn_atk_socket_get_type;
|
||||
pfn_atk_socket_get_type = (AtkGetTypeType)
|
||||
PR_FindFunctionSymbol(sATKLib,
|
||||
AtkSocketAccessible::sATKSocketGetTypeSymbol);
|
||||
if (pfn_atk_socket_get_type) {
|
||||
AtkSocketAccessible::g_atk_socket_type =
|
||||
pfn_atk_socket_get_type();
|
||||
AtkSocketAccessible::g_atk_socket_embed = (AtkSocketEmbedType)
|
||||
PR_FindFunctionSymbol(sATKLib,
|
||||
AtkSocketAccessible
|
||||
::sATKSocketEmbedSymbol);
|
||||
AtkSocketAccessible::gCanEmbed =
|
||||
AtkSocketAccessible::g_atk_socket_type != G_TYPE_INVALID &&
|
||||
AtkSocketAccessible::g_atk_socket_embed;
|
||||
}
|
||||
}
|
||||
sATKChecked = PR_TRUE;
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,5 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2:
|
||||
*/
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
@ -45,8 +45,6 @@
|
||||
#include "nsCoreUtils.h"
|
||||
|
||||
#include "nsIDOMDocument.h"
|
||||
#include "nsIDOMDocumentView.h"
|
||||
#include "nsIDOMAbstractView.h"
|
||||
#include "nsIDOMWindowInternal.h"
|
||||
#include "nsIDocShellTreeItem.h"
|
||||
#include "nsIInterfaceRequestorUtils.h"
|
||||
@ -68,66 +66,19 @@ componentInterfaceInitCB(AtkComponentIface *aIface)
|
||||
}
|
||||
|
||||
AtkObject*
|
||||
refAccessibleAtPointCB(AtkComponent *aComponent,
|
||||
gint aAccX, gint aAccY,
|
||||
refAccessibleAtPointCB(AtkComponent* aComponent, gint aAccX, gint aAccY,
|
||||
AtkCoordType aCoordType)
|
||||
{
|
||||
nsAccessibleWrap *accWrap = GetAccessibleWrap(ATK_OBJECT(aComponent));
|
||||
if (!accWrap || nsAccUtils::MustPrune(accWrap))
|
||||
return nsnull;
|
||||
|
||||
// nsIAccessible getChildAtPoint (x,y) is in screen pixels.
|
||||
if (aCoordType == ATK_XY_WINDOW) {
|
||||
nsIntPoint winCoords =
|
||||
nsCoreUtils::GetScreenCoordsForWindow(accWrap->GetNode());
|
||||
aAccX += winCoords.x;
|
||||
aAccY += winCoords.y;
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIAccessible> pointAcc;
|
||||
accWrap->GetChildAtPoint(aAccX, aAccY, getter_AddRefs(pointAcc));
|
||||
if (!pointAcc) {
|
||||
return nsnull;
|
||||
}
|
||||
|
||||
AtkObject *atkObj = nsAccessibleWrap::GetAtkObject(pointAcc);
|
||||
if (atkObj) {
|
||||
g_object_ref(atkObj);
|
||||
}
|
||||
return atkObj;
|
||||
return refAccessibleAtPointHelper(GetAccessibleWrap(ATK_OBJECT(aComponent)),
|
||||
aAccX, aAccY, aCoordType);
|
||||
}
|
||||
|
||||
void
|
||||
getExtentsCB(AtkComponent *aComponent,
|
||||
gint *aAccX,
|
||||
gint *aAccY,
|
||||
gint *aAccWidth,
|
||||
gint *aAccHeight,
|
||||
AtkCoordType aCoordType)
|
||||
getExtentsCB(AtkComponent* aComponent, gint* aX, gint* aY,
|
||||
gint* aWidth, gint* aHeight, AtkCoordType aCoordType)
|
||||
{
|
||||
*aAccX = *aAccY = *aAccWidth = *aAccHeight = 0;
|
||||
|
||||
nsAccessibleWrap *accWrap = GetAccessibleWrap(ATK_OBJECT(aComponent));
|
||||
if (!accWrap)
|
||||
return;
|
||||
|
||||
PRInt32 nsAccX, nsAccY, nsAccWidth, nsAccHeight;
|
||||
// Returned in screen coordinates
|
||||
nsresult rv = accWrap->GetBounds(&nsAccX, &nsAccY,
|
||||
&nsAccWidth, &nsAccHeight);
|
||||
if (NS_FAILED(rv))
|
||||
return;
|
||||
if (aCoordType == ATK_XY_WINDOW) {
|
||||
nsIntPoint winCoords =
|
||||
nsCoreUtils::GetScreenCoordsForWindow(accWrap->GetNode());
|
||||
nsAccX -= winCoords.x;
|
||||
nsAccY -= winCoords.y;
|
||||
}
|
||||
|
||||
*aAccX = nsAccX;
|
||||
*aAccY = nsAccY;
|
||||
*aAccWidth = nsAccWidth;
|
||||
*aAccHeight = nsAccHeight;
|
||||
getExtentsHelper(GetAccessibleWrap(ATK_OBJECT(aComponent)),
|
||||
aX, aY, aWidth, aHeight, aCoordType);
|
||||
}
|
||||
|
||||
gboolean
|
||||
@ -140,3 +91,58 @@ grabFocusCB(AtkComponent *aComponent)
|
||||
nsresult rv = accWrap->TakeFocus();
|
||||
return (NS_FAILED(rv)) ? FALSE : TRUE;
|
||||
}
|
||||
|
||||
AtkObject*
|
||||
refAccessibleAtPointHelper(nsAccessibleWrap* aAccWrap, gint aX, gint aY,
|
||||
AtkCoordType aCoordType)
|
||||
{
|
||||
if (!aAccWrap || aAccWrap->IsDefunct() || nsAccUtils::MustPrune(aAccWrap))
|
||||
return nsnull;
|
||||
|
||||
// nsAccessible::GetChildAtPoint(x,y) is in screen pixels.
|
||||
if (aCoordType == ATK_XY_WINDOW) {
|
||||
nsIntPoint winCoords =
|
||||
nsCoreUtils::GetScreenCoordsForWindow(aAccWrap->GetNode());
|
||||
aX += winCoords.x;
|
||||
aY += winCoords.y;
|
||||
}
|
||||
|
||||
nsAccessible* accAtPoint = aAccWrap->GetChildAtPoint(aX, aY,
|
||||
nsAccessible::eDirectChild);
|
||||
if (!accAtPoint)
|
||||
return nsnull;
|
||||
|
||||
AtkObject* atkObj = nsAccessibleWrap::GetAtkObject(accAtPoint);
|
||||
if (atkObj)
|
||||
g_object_ref(atkObj);
|
||||
return atkObj;
|
||||
}
|
||||
|
||||
void
|
||||
getExtentsHelper(nsAccessibleWrap* aAccWrap,
|
||||
gint* aX, gint* aY, gint* aWidth, gint* aHeight,
|
||||
AtkCoordType aCoordType)
|
||||
{
|
||||
*aX = *aY = *aWidth = *aHeight = 0;
|
||||
|
||||
if (!aAccWrap || aAccWrap->IsDefunct())
|
||||
return;
|
||||
|
||||
PRInt32 x = 0, y = 0, width = 0, height = 0;
|
||||
// Returned in screen coordinates
|
||||
nsresult rv = aAccWrap->GetBounds(&x, &y, &width, &height);
|
||||
if (NS_FAILED(rv))
|
||||
return;
|
||||
|
||||
if (aCoordType == ATK_XY_WINDOW) {
|
||||
nsIntPoint winCoords =
|
||||
nsCoreUtils::GetScreenCoordsForWindow(aAccWrap->GetNode());
|
||||
x -= winCoords.x;
|
||||
y -= winCoords.y;
|
||||
}
|
||||
|
||||
*aX = x;
|
||||
*aY = y;
|
||||
*aWidth = width;
|
||||
*aHeight = height;
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2:
|
||||
*/
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
@ -48,20 +48,18 @@ G_BEGIN_DECLS
|
||||
/* component interface callbacks */
|
||||
void componentInterfaceInitCB(AtkComponentIface* aIface);
|
||||
AtkObject* refAccessibleAtPointCB(AtkComponent* aComponent,
|
||||
gint aAccX, gint aAccY,
|
||||
gint aX, gint aY,
|
||||
AtkCoordType aCoordType);
|
||||
void getExtentsCB(AtkComponent* aComponent,
|
||||
gint *aAccX, gint *aAccY,
|
||||
gint *aAccWidth, gint *aAccHeight,
|
||||
gint* aX, gint* aY, gint* aWidth, gint* aHeight,
|
||||
AtkCoordType aCoordType);
|
||||
/* the "contains", "get_position", "get_size" can take advantage of
|
||||
* "get_extents", there is no need to implement them now.
|
||||
*/
|
||||
gboolean grabFocusCB(AtkComponent* aComponent);
|
||||
|
||||
/* what are missing now for atk component */
|
||||
|
||||
/* ==================================================
|
||||
/* what are missing now for atk component:
|
||||
*
|
||||
* add_focus_handler
|
||||
* remove_focus_handler
|
||||
* set_extents
|
||||
@ -69,8 +67,14 @@ gboolean grabFocusCB(AtkComponent *aComponent);
|
||||
* set_size
|
||||
* get_layer
|
||||
* get_mdi_zorder
|
||||
* ==================================================
|
||||
*/
|
||||
|
||||
AtkObject* refAccessibleAtPointHelper(nsAccessibleWrap* aAccWrap,
|
||||
gint aX, gint aY, AtkCoordType aCoordType);
|
||||
void getExtentsHelper(nsAccessibleWrap* aAccWrap,
|
||||
gint* aX, gint* aY, gint* aWidth, gint* aHeight,
|
||||
AtkCoordType aCoordType);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __MAI_INTERFACE_COMPONENT_H__ */
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* vim:expandtab:shiftwidth=4:tabstop=4:
|
||||
*/
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,6 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2:
|
||||
*/
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -1,4 +1,5 @@
|
||||
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* vim:expandtab:shiftwidth=2:tabstop=2: */
|
||||
/* ***** BEGIN LICENSE BLOCK *****
|
||||
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
*
|
||||
|
@ -65,7 +65,7 @@
|
||||
#include "nsIDOMHTMLOptionElement.h"
|
||||
#include "nsIDOMXULElement.h"
|
||||
#include "nsIHTMLDocument.h"
|
||||
#include "nsIImageFrame.h"
|
||||
#include "nsImageFrame.h"
|
||||
#include "nsILink.h"
|
||||
#include "nsIObserverService.h"
|
||||
#include "nsIPluginInstance.h"
|
||||
@ -95,6 +95,11 @@
|
||||
#include "nsHTMLWin32ObjectAccessible.h"
|
||||
#endif
|
||||
|
||||
// For embedding plugin accessibles
|
||||
#ifdef MOZ_ACCESSIBILITY_ATK
|
||||
#include "AtkSocketAccessible.h"
|
||||
#endif
|
||||
|
||||
#ifndef DISABLE_XFORMS_HOOKS
|
||||
#include "nsXFormsFormControlsAccessible.h"
|
||||
#include "nsXFormsWidgetsAccessible.h"
|
||||
@ -339,11 +344,12 @@ nsAccessibilityService::CreateHTMLObjectFrameAccessible(nsObjectFrame* aFrame,
|
||||
return CreateOuterDocAccessible(aContent, aPresShell);
|
||||
}
|
||||
|
||||
#ifdef XP_WIN
|
||||
#if defined(XP_WIN) || defined(MOZ_ACCESSIBILITY_ATK)
|
||||
// 2) for plugins
|
||||
nsCOMPtr<nsIPluginInstance> pluginInstance;
|
||||
aFrame->GetPluginInstance(*getter_AddRefs(pluginInstance));
|
||||
if (pluginInstance) {
|
||||
if (NS_SUCCEEDED(aFrame->GetPluginInstance(*getter_AddRefs(pluginInstance))) &&
|
||||
pluginInstance) {
|
||||
#ifdef XP_WIN
|
||||
// Note: pluginPort will be null if windowless.
|
||||
HWND pluginPort = nsnull;
|
||||
aFrame->GetPluginPort(&pluginPort);
|
||||
@ -353,6 +359,22 @@ nsAccessibilityService::CreateHTMLObjectFrameAccessible(nsObjectFrame* aFrame,
|
||||
pluginPort);
|
||||
NS_IF_ADDREF(accessible);
|
||||
return accessible;
|
||||
|
||||
#elif MOZ_ACCESSIBILITY_ATK
|
||||
if (!AtkSocketAccessible::gCanEmbed)
|
||||
return nsnull;
|
||||
|
||||
nsCString plugId;
|
||||
nsresult rv = pluginInstance->GetValueFromPlugin(
|
||||
NPPVpluginNativeAccessibleAtkPlugId, &plugId);
|
||||
if (NS_SUCCEEDED(rv) && !plugId.IsVoid()) {
|
||||
AtkSocketAccessible* socketAccessible =
|
||||
new AtkSocketAccessible(aContent, weakShell, plugId);
|
||||
|
||||
NS_IF_ADDREF(socketAccessible);
|
||||
return socketAccessible;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
@ -1244,7 +1266,7 @@ nsAccessibilityService::GetAreaAccessible(nsIFrame* aImageFrame,
|
||||
nsAccessible** aImageAccessible)
|
||||
{
|
||||
// Check if frame is an image frame, and content is <area>.
|
||||
nsIImageFrame *imageFrame = do_QueryFrame(aImageFrame);
|
||||
nsImageFrame *imageFrame = do_QueryFrame(aImageFrame);
|
||||
if (!imageFrame)
|
||||
return nsnull;
|
||||
|
||||
|
@ -43,15 +43,12 @@
|
||||
#include "nsAccessNode.h"
|
||||
|
||||
#include "nsIDocument.h"
|
||||
#include "nsIDOMAbstractView.h"
|
||||
#include "nsIDOM3Node.h"
|
||||
#include "nsIDOMDocument.h"
|
||||
#include "nsIDOMDocumentView.h"
|
||||
#include "nsIDOMHTMLDocument.h"
|
||||
#include "nsIDOMHTMLElement.h"
|
||||
#include "nsIDOMNodeList.h"
|
||||
#include "nsIDOMRange.h"
|
||||
#include "nsIDOMViewCSS.h"
|
||||
#include "nsIDOMWindowInternal.h"
|
||||
#include "nsIDOMXULElement.h"
|
||||
#include "nsIDocShell.h"
|
||||
@ -425,13 +422,12 @@ nsCoreUtils::GetScreenCoordsForWindow(nsINode *aNode)
|
||||
nsCOMPtr<nsIDocShellTreeItem> rootTreeItem;
|
||||
treeItem->GetRootTreeItem(getter_AddRefs(rootTreeItem));
|
||||
nsCOMPtr<nsIDOMDocument> domDoc = do_GetInterface(rootTreeItem);
|
||||
nsCOMPtr<nsIDOMDocumentView> docView(do_QueryInterface(domDoc));
|
||||
if (!docView)
|
||||
if (!domDoc)
|
||||
return coords;
|
||||
|
||||
nsCOMPtr<nsIDOMAbstractView> abstractView;
|
||||
docView->GetDefaultView(getter_AddRefs(abstractView));
|
||||
nsCOMPtr<nsIDOMWindowInternal> windowInter(do_QueryInterface(abstractView));
|
||||
nsCOMPtr<nsIDOMWindow> window;
|
||||
domDoc->GetDefaultView(getter_AddRefs(window));
|
||||
nsCOMPtr<nsIDOMWindowInternal> windowInter(do_QueryInterface(window));
|
||||
if (!windowInter)
|
||||
return coords;
|
||||
|
||||
@ -597,14 +593,14 @@ nsCoreUtils::GetComputedStyleDeclaration(const nsAString& aPseudoElt,
|
||||
if (!document)
|
||||
return nsnull;
|
||||
|
||||
nsCOMPtr<nsIDOMViewCSS> viewCSS(do_QueryInterface(document->GetWindow()));
|
||||
if (!viewCSS)
|
||||
nsCOMPtr<nsIDOMWindow> window = do_QueryInterface(document->GetWindow());
|
||||
if (!window)
|
||||
return nsnull;
|
||||
|
||||
nsIDOMCSSStyleDeclaration* cssDecl = nsnull;
|
||||
nsCOMPtr<nsIDOMCSSStyleDeclaration> cssDecl;
|
||||
nsCOMPtr<nsIDOMElement> domElement(do_QueryInterface(content));
|
||||
viewCSS->GetComputedStyle(domElement, aPseudoElt, &cssDecl);
|
||||
return cssDecl;
|
||||
window->GetComputedStyle(domElement, aPseudoElt, getter_AddRefs(cssDecl));
|
||||
return cssDecl.forget();
|
||||
}
|
||||
|
||||
already_AddRefed<nsIBoxObject>
|
||||
|
@ -193,15 +193,15 @@ nsRootAccessible::NativeState()
|
||||
|
||||
#ifdef MOZ_XUL
|
||||
PRUint32 chromeFlags = GetChromeFlags();
|
||||
if (chromeFlags & nsIWebBrowserChrome::CHROME_WINDOW_RESIZE) {
|
||||
if (chromeFlags & nsIWebBrowserChrome::CHROME_WINDOW_RESIZE)
|
||||
states |= states::SIZEABLE;
|
||||
}
|
||||
if (chromeFlags & nsIWebBrowserChrome::CHROME_TITLEBAR) {
|
||||
// If it has a titlebar it's movable
|
||||
// XXX unless it's minimized or maximized, but not sure
|
||||
// how to detect that
|
||||
if (chromeFlags & nsIWebBrowserChrome::CHROME_TITLEBAR)
|
||||
states |= states::MOVEABLE;
|
||||
}
|
||||
if (chromeFlags & nsIWebBrowserChrome::CHROME_MODAL)
|
||||
states |= states::MODAL;
|
||||
#endif
|
||||
|
||||
nsCOMPtr<nsIFocusManager> fm = do_GetService(FOCUSMANAGER_CONTRACTID);
|
||||
@ -215,12 +215,6 @@ nsRootAccessible::NativeState()
|
||||
states |= states::ACTIVE;
|
||||
}
|
||||
|
||||
#ifdef MOZ_XUL
|
||||
if (GetChromeFlags() & nsIWebBrowserChrome::CHROME_MODAL) {
|
||||
states |= states::MODAL;
|
||||
}
|
||||
#endif
|
||||
|
||||
return states;
|
||||
}
|
||||
|
||||
|
@ -47,8 +47,8 @@
|
||||
#include "nsIDOMElement.h"
|
||||
#include "nsIDOMHTMLAreaElement.h"
|
||||
#include "nsIFrame.h"
|
||||
#include "nsIImageFrame.h"
|
||||
#include "nsIImageMap.h"
|
||||
#include "nsImageFrame.h"
|
||||
#include "nsImageMap.h"
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// nsHTMLImageMapAccessible
|
||||
@ -203,14 +203,12 @@ nsHTMLAreaAccessible::GetBounds(PRInt32 *aX, PRInt32 *aY,
|
||||
|
||||
nsIFrame *frame = GetFrame();
|
||||
NS_ENSURE_TRUE(frame, NS_ERROR_FAILURE);
|
||||
nsIImageFrame *imageFrame = do_QueryFrame(frame);
|
||||
nsImageFrame *imageFrame = do_QueryFrame(frame);
|
||||
|
||||
nsCOMPtr<nsIImageMap> map;
|
||||
imageFrame->GetImageMap(presContext, getter_AddRefs(map));
|
||||
nsImageMap* map = imageFrame->GetImageMap(presContext);
|
||||
NS_ENSURE_TRUE(map, NS_ERROR_FAILURE);
|
||||
|
||||
nsRect rect;
|
||||
nsIntRect orgRectPixels;
|
||||
nsresult rv = map->GetBoundsForAreaContent(mContent, rect);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
@ -223,7 +221,7 @@ nsHTMLAreaAccessible::GetBounds(PRInt32 *aX, PRInt32 *aY,
|
||||
*aHeight = presContext->AppUnitsToDevPixels(rect.height - rect.y);
|
||||
|
||||
// Put coords in absolute screen coords
|
||||
orgRectPixels = frame->GetScreenRectExternal();
|
||||
nsIntRect orgRectPixels = frame->GetScreenRectExternal();
|
||||
*aX += orgRectPixels.x;
|
||||
*aY += orgRectPixels.y;
|
||||
|
||||
|
@ -47,11 +47,9 @@
|
||||
|
||||
#include "nsIClipboard.h"
|
||||
#include "nsContentCID.h"
|
||||
#include "nsIDOMAbstractView.h"
|
||||
#include "nsIDOMCharacterData.h"
|
||||
#include "nsIDOMDocument.h"
|
||||
#include "nsPIDOMWindow.h"
|
||||
#include "nsIDOMDocumentView.h"
|
||||
#include "nsIDOMRange.h"
|
||||
#include "nsIDOMNSRange.h"
|
||||
#include "nsIDOMWindowInternal.h"
|
||||
|
@ -52,7 +52,6 @@
|
||||
#include "nsIDocument.h"
|
||||
#include "nsIDOMNodeList.h"
|
||||
#include "nsIDOMNSHTMLElement.h"
|
||||
#include "nsIDOMViewCSS.h"
|
||||
#include "nsIFrame.h"
|
||||
#include "nsINameSpaceManager.h"
|
||||
#include "nsIPrefService.h"
|
||||
|
@ -15,6 +15,12 @@
|
||||
</targetApplication>
|
||||
</versionRange>
|
||||
</emItem>
|
||||
<emItem id="krupa.raj+545@gmail.com">
|
||||
<versionRange severity="2"/>
|
||||
</emItem>
|
||||
<emItem id="krups@krup12s.com">
|
||||
<versionRange severity="3"/>
|
||||
</emItem>
|
||||
<emItem id="langpack-vi-VN@firefox.mozilla.org">
|
||||
<versionRange minVersion="2.0" maxVersion="2.0"/>
|
||||
</emItem>
|
||||
@ -36,6 +42,9 @@
|
||||
<emItem id="msntoolbar@msn.com">
|
||||
<versionRange minVersion=" " maxVersion="6.*"/>
|
||||
</emItem>
|
||||
<emItem id="near799@wdios.com" os="Android">
|
||||
<versionRange minVersion="0.8" maxVersion="1.0" severity="3"/>
|
||||
</emItem>
|
||||
<emItem id="personas@christopher.beard">
|
||||
<versionRange minVersion="1.6" maxVersion="1.6">
|
||||
<targetApplication id="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}">
|
||||
@ -46,6 +55,9 @@
|
||||
<emItem id="ShopperReports@ShopperReports.com">
|
||||
<versionRange minVersion="3.1.22.0" maxVersion="3.1.22.0"/>
|
||||
</emItem>
|
||||
<emItem id="sidecar-test-addon20110103118@amazon.com" os="MACOSX, Windows, Linux">
|
||||
<versionRange severity="3"/>
|
||||
</emItem>
|
||||
<emItem id="support@daemon-tools.cc">
|
||||
<versionRange minVersion=" " maxVersion="1.0.0.5"/>
|
||||
</emItem>
|
||||
@ -184,5 +196,38 @@
|
||||
<driverVersion>7.0.0.0</driverVersion>
|
||||
<driverVersionComparator>GREATER_THAN_OR_EQUAL</driverVersionComparator>
|
||||
</gfxBlacklistEntry>
|
||||
<gfxBlacklistEntry>
|
||||
<os>MAC OS X 10.5.8</os>
|
||||
<vendor>0x10de</vendor>
|
||||
<feature>DIRECT3D_9_LAYERS</feature>
|
||||
<driverVersion>7.0.0.0</driverVersion>
|
||||
<driverVersionComparator>GREATER_THAN_OR_EQUAL</driverVersionComparator>
|
||||
</gfxBlacklistEntry>
|
||||
<gfxBlacklistEntry>
|
||||
<os>MAC OS X 10.5.8</os>
|
||||
<vendor>0x10de</vendor>
|
||||
<feature>DIRECT3D_9_LAYERS</feature>
|
||||
<featureStatus>BLOCKED_DRIVER_VERSION</featureStatus>
|
||||
<driverVersion>7.0.0.0</driverVersion>
|
||||
<driverVersionComparator>GREATER_THAN_OR_EQUAL</driverVersionComparator>
|
||||
</gfxBlacklistEntry>
|
||||
<gfxBlacklistEntry>
|
||||
<os>MAC OS X 10.6</os>
|
||||
<vendor>0x10de</vendor>
|
||||
<devices>
|
||||
<device>0x0a6c</device>
|
||||
</devices>
|
||||
<feature>DIRECT3D_9_LAYERS</feature>
|
||||
<featureStatus>BLOCKED_DRIVER_VERSION</featureStatus>
|
||||
<driverVersion>8.17.12.5896</driverVersion>
|
||||
<driverVersionComparator>LESS_THAN_OR_EQUAL</driverVersionComparator>
|
||||
</gfxBlacklistEntry>
|
||||
<gfxBlacklistEntry>
|
||||
<os>MAC OS X 10.6</os>
|
||||
<vendor>0x10de</vendor>
|
||||
<feature>DIRECT3D_9_LAYERS</feature>
|
||||
<driverVersion>7.0.0.0</driverVersion>
|
||||
<driverVersionComparator>GREATER_THAN_OR_EQUAL</driverVersionComparator>
|
||||
</gfxBlacklistEntry>
|
||||
</gfxItems>
|
||||
</blocklist>
|
||||
|
@ -55,6 +55,7 @@ const POPUP_SHOW_ON_RESULTS = "extensions.testpilot.popup.showOnNewResults";
|
||||
const POPUP_CHECK_INTERVAL = "extensions.testpilot.popup.delayAfterStartup";
|
||||
const POPUP_REMINDER_INTERVAL = "extensions.testpilot.popup.timeBetweenChecks";
|
||||
const ALWAYS_SUBMIT_DATA = "extensions.testpilot.alwaysSubmitData";
|
||||
const UPDATE_CHANNEL_PREF = "app.update.channel";
|
||||
const LOG_FILE_NAME = "TestPilotErrorLog.log";
|
||||
const RANDOM_DEPLOY_PREFIX = "extensions.testpilot.deploymentRandomizer";
|
||||
|
||||
|
@ -76,10 +76,9 @@ pref("extensions.update.autoUpdateDefault", true);
|
||||
// Dictionary download preference
|
||||
pref("browser.dictionaries.download.url", "https://addons.mozilla.org/%LOCALE%/%APP%/dictionaries/");
|
||||
|
||||
// Update Timer Manager preferences
|
||||
// Interval: When all registered timers should be checked (in milliseconds)
|
||||
// default=10 minutes
|
||||
pref("app.update.timer", 600000);
|
||||
// The minimum delay in seconds for the timer to fire.
|
||||
// default=2 minutes
|
||||
pref("app.update.timerMinimumDelay", 120);
|
||||
|
||||
// App-specific update preferences
|
||||
|
||||
@ -347,10 +346,6 @@ pref("browser.search.update.log", false);
|
||||
// Check whether we need to perform engine updates every 6 hours
|
||||
pref("browser.search.update.interval", 21600);
|
||||
|
||||
// Whether or not microsummary and generator updates are enabled
|
||||
pref("browser.microsummary.enabled", true);
|
||||
pref("browser.microsummary.updateGenerators", true);
|
||||
|
||||
// enable search suggestions by default
|
||||
pref("browser.search.suggest.enabled", true);
|
||||
|
||||
|
@ -597,6 +597,8 @@ var gChannelSelector = {
|
||||
selectChannel: function(aSelectedItem) {
|
||||
document.getElementById("channelDescriptionDeck").selectedPanel =
|
||||
document.getElementById(aSelectedItem.value + "Description");
|
||||
document.getElementById("channelMenulist").setAttribute("aria-describedby",
|
||||
aSelectedItem.value + "Description");
|
||||
},
|
||||
|
||||
cancel: function() {
|
||||
|
@ -67,6 +67,7 @@
|
||||
#else
|
||||
title="&aboutDialog.title;"
|
||||
#endif
|
||||
aria-describedby="version distribution distributionId"
|
||||
>
|
||||
|
||||
<script type="application/javascript" src="chrome://browser/content/aboutDialog.js"/>
|
||||
@ -82,7 +83,7 @@
|
||||
<!-- Make sure the selectedIndex attribute is always set so that the CSS
|
||||
selectors for transitions work -->
|
||||
<deck id="contentDeck" selectedIndex="0">
|
||||
<vbox id="detailsBox">
|
||||
<vbox id="detailsBox" aria-describedby="communityDesc contributeDesc">
|
||||
<vbox id="updateBox">
|
||||
#ifdef MOZ_UPDATER
|
||||
<deck id="updateDeck" orient="vertical">
|
||||
@ -119,10 +120,10 @@
|
||||
<description class="text-blurb" id="currentChannelText" hidden="true">
|
||||
&channel.description.start;<label id="currentChannel"/>&channel.description.end;<label id="channelChangeLink" class="text-link" onclick="gChannelSelector.show();">&channel.change;</label>
|
||||
</description>
|
||||
<description class="text-blurb">
|
||||
<description class="text-blurb" id="communityDesc">
|
||||
&community.start2;<label class="text-link" href="http://www.mozilla.org/">&community.mozillaLink;</label>&community.middle2;<label class="text-link" href="about:credits">&community.creditsLink;</label>&community.end2;
|
||||
</description>
|
||||
<description class="text-blurb">
|
||||
<description class="text-blurb" id="contributeDesc">
|
||||
&contribute.start;<label class="text-link" href="http://www.mozilla.org/contribute/">&contribute.getInvolvedLink;</label>&contribute.end;
|
||||
</description>
|
||||
</vbox>
|
||||
@ -130,7 +131,7 @@
|
||||
<vbox id="channelSelector">
|
||||
<hbox pack="start" align="center">
|
||||
<label id="channelSelectorStart">&channel.selector.start;</label>
|
||||
<menulist id="channelMenulist" onselect="gChannelSelector.selectChannel(this.selectedItem);">
|
||||
<menulist id="channelMenulist" onselect="gChannelSelector.selectChannel(this.selectedItem);" aria-labelledby="channelSelectorStart channelMenulist channelSelectorEnd">
|
||||
<menupopup>
|
||||
<menuitem id="releaseMenuitem" label="Release" value="release"/>
|
||||
<menuitem id="betaMenuitem" label="Beta" value="beta"/>
|
||||
@ -138,7 +139,7 @@
|
||||
<menuitem id="auroraMenuitem" label="Aurora" value="aurora"/>
|
||||
</menupopup>
|
||||
</menulist>
|
||||
<label>&channel.selector.end;</label>
|
||||
<label id="channelSelectorEnd">&channel.selector.end;</label>
|
||||
</hbox>
|
||||
|
||||
<deck id="channelDescriptionDeck" selectedIndex="0">
|
||||
|
@ -22,6 +22,7 @@
|
||||
# Contributor(s):
|
||||
# Ehsan Akhgari <ehsan.akhgari@gmail.com>
|
||||
# Rob Campbell <rcampbell@mozilla.com>
|
||||
# Steffen Wilberg <steffen.wilberg@web.de>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
@ -379,16 +380,15 @@
|
||||
oncommand="BrowserGoHome(event);"
|
||||
onclick="checkForMiddleClick(this, event);"
|
||||
key="goHome"/>
|
||||
<menuseparator id="historyMenuHomeSeparator"
|
||||
class="show-only-for-keyboard"/>
|
||||
<menuitem id="menu_showAllHistory"
|
||||
label="&showAllHistoryCmd2.label;"
|
||||
#ifndef XP_MACOSX
|
||||
key="showAllHistoryKb"
|
||||
#endif
|
||||
command="Browser:ShowAllHistory"/>
|
||||
<menuseparator id="startHistorySeparator"/>
|
||||
<menuseparator id="endHistorySeparator"
|
||||
class="hide-if-empty-places-result"
|
||||
builder="end"/>
|
||||
<menuseparator id="showAllHistorySeparator"/>
|
||||
#ifdef MOZ_SERVICES_SYNC
|
||||
<menuitem id="sync-tabs-menuitem"
|
||||
label="&syncTabsMenu.label;"
|
||||
@ -420,6 +420,8 @@
|
||||
#endif
|
||||
onpopupshowing="document.getElementById('history-menu')._placesView.populateUndoWindowSubmenu();"/>
|
||||
</menu>
|
||||
<menuseparator id="startHistorySeparator"
|
||||
class="hide-if-empty-places-result"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
@ -441,6 +443,11 @@
|
||||
if (!this.parentNode._placesView)
|
||||
new PlacesMenu(event, 'place:folder=BOOKMARKS_MENU');"
|
||||
tooltip="bhTooltip" popupsinherittooltip="true">
|
||||
<menuitem id="bookmarksShowAll"
|
||||
label="&showAllBookmarks2.label;"
|
||||
command="Browser:ShowAllBookmarks"
|
||||
key="manBookmarkKb"/>
|
||||
<menuseparator id="organizeBookmarksSeparator"/>
|
||||
<menuitem id="menu_bookmarkThisPage"
|
||||
label="&bookmarkThisPageCmd.label;"
|
||||
command="Browser:AddBookmarkAs"
|
||||
@ -469,11 +476,7 @@
|
||||
class="show-only-for-keyboard"
|
||||
command="Browser:BookmarkAllTabs"
|
||||
key="bookmarkAllTabsKb"/>
|
||||
<menuitem id="bookmarksShowAll"
|
||||
label="&showAllBookmarks2.label;"
|
||||
command="Browser:ShowAllBookmarks"
|
||||
key="manBookmarkKb"/>
|
||||
<menuseparator id="organizeBookmarksSeparator"/>
|
||||
<menuseparator id="bookmarksToolbarSeparator"/>
|
||||
<menu id="bookmarksToolbarFolderMenu"
|
||||
class="menu-iconic bookmark-item"
|
||||
label="&personalbarCmd.label;"
|
||||
@ -486,7 +489,13 @@
|
||||
onpopupshowing="if (!this.parentNode._placesView)
|
||||
new PlacesMenu(event, 'place:folder=TOOLBAR');"/>
|
||||
</menu>
|
||||
<menuseparator/>
|
||||
<menuseparator id="bookmarksMenuItemsSeparator"/>
|
||||
<!-- Bookmarks menu items -->
|
||||
<menuseparator builder="end"
|
||||
class="hide-if-empty-places-result"/>
|
||||
<menuitem id="menu_unsortedBookmarks"
|
||||
label="&unsortedBookmarksCmd.label;"
|
||||
oncommand="PlacesCommandHook.showPlacesOrganizer('UnfiledBookmarks');"/>
|
||||
</menupopup>
|
||||
</menu>
|
||||
|
||||
|
@ -489,7 +489,7 @@ function HistoryMenu(aPopupShowingEvent) {
|
||||
"@mozilla.org/browser/sessionstore;1",
|
||||
"nsISessionStore");
|
||||
PlacesMenu.call(this, aPopupShowingEvent,
|
||||
"place:redirectsMode=2&sort=4&maxResults=10");
|
||||
"place:redirectsMode=2&sort=4&maxResults=15");
|
||||
}
|
||||
|
||||
HistoryMenu.prototype = {
|
||||
|
@ -84,6 +84,8 @@ var gLastValidURLStr = "";
|
||||
var gInPrintPreviewMode = false;
|
||||
var gDownloadMgr = null;
|
||||
var gContextMenu = null; // nsContextMenu instance
|
||||
var gDelayedStartupTimeoutId;
|
||||
var gStartupRan = false;
|
||||
|
||||
#ifndef XP_MACOSX
|
||||
var gEditUIVisible = true;
|
||||
@ -1332,7 +1334,8 @@ function BrowserStartup() {
|
||||
|
||||
retrieveToolbarIconsizesFromTheme();
|
||||
|
||||
setTimeout(delayedStartup, 0, isLoadingBlank, mustLoadSidebar);
|
||||
gDelayedStartupTimeoutId = setTimeout(delayedStartup, 0, isLoadingBlank, mustLoadSidebar);
|
||||
gStartupRan = true;
|
||||
}
|
||||
|
||||
function HandleAppCommandEvent(evt) {
|
||||
@ -1452,6 +1455,8 @@ function prepareForStartup() {
|
||||
}
|
||||
|
||||
function delayedStartup(isLoadingBlank, mustLoadSidebar) {
|
||||
gDelayedStartupTimeoutId = null;
|
||||
|
||||
Services.obs.addObserver(gSessionHistoryObserver, "browser:purge-session-history", false);
|
||||
Services.obs.addObserver(gXPInstallObserver, "addon-install-disabled", false);
|
||||
Services.obs.addObserver(gXPInstallObserver, "addon-install-started", false);
|
||||
@ -1577,22 +1582,10 @@ function delayedStartup(isLoadingBlank, mustLoadSidebar) {
|
||||
gPrefService.addObserver(ctrlTab.prefName, ctrlTab, false);
|
||||
gPrefService.addObserver(allTabs.prefName, allTabs, false);
|
||||
|
||||
// Initialize the microsummary service by retrieving it, prompting its factory
|
||||
// to create its singleton, whose constructor initializes the service.
|
||||
// Started 4 seconds after delayedStartup (before the livemarks service below).
|
||||
setTimeout(function() {
|
||||
try {
|
||||
Cc["@mozilla.org/microsummary/service;1"].getService(Ci.nsIMicrosummaryService);
|
||||
} catch (ex) {
|
||||
Components.utils.reportError("Failed to init microsummary service:\n" + ex);
|
||||
}
|
||||
}, 4000);
|
||||
|
||||
// Delayed initialization of the livemarks update timer.
|
||||
// Livemark updates don't need to start until after bookmark UI
|
||||
// such as the toolbar has initialized. Starting 5 seconds after
|
||||
// delayedStartup in order to stagger this after the microsummary
|
||||
// service (see above) and before the download manager starts (see below).
|
||||
// delayedStartup in order to stagger this before the download manager starts.
|
||||
setTimeout(function() PlacesUtils.livemarks.start(), 5000);
|
||||
|
||||
// Initialize the download manager some time after the app starts so that
|
||||
@ -1672,16 +1665,16 @@ function delayedStartup(isLoadingBlank, mustLoadSidebar) {
|
||||
Services.obs.notifyObservers(window, "browser-delayed-startup-finished", "");
|
||||
}
|
||||
|
||||
function BrowserShutdown()
|
||||
{
|
||||
if (Win7Features)
|
||||
Win7Features.onCloseWindow();
|
||||
function BrowserShutdown() {
|
||||
// In certain scenarios it's possible for unload to be fired before onload,
|
||||
// (e.g. if the window is being closed after browser.js loads but before the
|
||||
// load completes). In that case, there's nothing to do here.
|
||||
if (!gStartupRan)
|
||||
return;
|
||||
|
||||
gPrefService.removeObserver(ctrlTab.prefName, ctrlTab);
|
||||
gPrefService.removeObserver(allTabs.prefName, allTabs);
|
||||
ctrlTab.uninit();
|
||||
// First clean up services initialized in BrowserStartup (or those whose
|
||||
// uninit methods don't depend on the services having been initialized).
|
||||
allTabs.uninit();
|
||||
TabView.uninit();
|
||||
|
||||
CombinedStopReload.uninit();
|
||||
|
||||
@ -1689,6 +1682,42 @@ function BrowserShutdown()
|
||||
|
||||
FullScreen.cleanup();
|
||||
|
||||
Services.obs.removeObserver(gPluginHandler.pluginCrashed, "plugin-crashed");
|
||||
|
||||
try {
|
||||
gBrowser.removeProgressListener(window.XULBrowserWindow);
|
||||
gBrowser.removeTabsProgressListener(window.TabsProgressListener);
|
||||
} catch (ex) {
|
||||
}
|
||||
|
||||
PlacesStarButton.uninit();
|
||||
|
||||
gPrivateBrowsingUI.uninit();
|
||||
|
||||
TabsInTitlebar.uninit();
|
||||
|
||||
var enumerator = Services.wm.getEnumerator(null);
|
||||
enumerator.getNext();
|
||||
if (!enumerator.hasMoreElements()) {
|
||||
document.persist("sidebar-box", "sidebarcommand");
|
||||
document.persist("sidebar-box", "width");
|
||||
document.persist("sidebar-box", "src");
|
||||
document.persist("sidebar-title", "value");
|
||||
}
|
||||
|
||||
// Now either cancel delayedStartup, or clean up the services initialized from
|
||||
// it.
|
||||
if (gDelayedStartupTimeoutId) {
|
||||
clearTimeout(gDelayedStartupTimeoutId);
|
||||
} else {
|
||||
if (Win7Features)
|
||||
Win7Features.onCloseWindow();
|
||||
|
||||
gPrefService.removeObserver(ctrlTab.prefName, ctrlTab);
|
||||
gPrefService.removeObserver(allTabs.prefName, allTabs);
|
||||
ctrlTab.uninit();
|
||||
TabView.uninit();
|
||||
|
||||
try {
|
||||
FullZoom.destroy();
|
||||
}
|
||||
@ -1702,17 +1731,8 @@ function BrowserShutdown()
|
||||
Services.obs.removeObserver(gXPInstallObserver, "addon-install-blocked");
|
||||
Services.obs.removeObserver(gXPInstallObserver, "addon-install-failed");
|
||||
Services.obs.removeObserver(gXPInstallObserver, "addon-install-complete");
|
||||
Services.obs.removeObserver(gPluginHandler.pluginCrashed, "plugin-crashed");
|
||||
Services.obs.removeObserver(gFormSubmitObserver, "invalidformsubmit");
|
||||
|
||||
try {
|
||||
gBrowser.removeProgressListener(window.XULBrowserWindow);
|
||||
gBrowser.removeTabsProgressListener(window.TabsProgressListener);
|
||||
} catch (ex) {
|
||||
}
|
||||
|
||||
PlacesStarButton.uninit();
|
||||
|
||||
try {
|
||||
gPrefService.removeObserver(gHomeButton.prefDomain, gHomeButton);
|
||||
} catch (ex) {
|
||||
@ -1721,20 +1741,11 @@ function BrowserShutdown()
|
||||
|
||||
BrowserOffline.uninit();
|
||||
OfflineApps.uninit();
|
||||
gPrivateBrowsingUI.uninit();
|
||||
IndexedDBPromptHelper.uninit();
|
||||
AddonManager.removeAddonListener(AddonsMgrListener);
|
||||
TabsInTitlebar.uninit();
|
||||
|
||||
var enumerator = Services.wm.getEnumerator(null);
|
||||
enumerator.getNext();
|
||||
if (!enumerator.hasMoreElements()) {
|
||||
document.persist("sidebar-box", "sidebarcommand");
|
||||
document.persist("sidebar-box", "width");
|
||||
document.persist("sidebar-box", "src");
|
||||
document.persist("sidebar-title", "value");
|
||||
}
|
||||
|
||||
// Final window teardown, do this last.
|
||||
window.XULBrowserWindow.destroy();
|
||||
window.XULBrowserWindow = null;
|
||||
window.QueryInterface(Components.interfaces.nsIInterfaceRequestor)
|
||||
@ -1750,8 +1761,7 @@ function BrowserShutdown()
|
||||
// nonBrowserWindowStartup(), nonBrowserWindowDelayedStartup(), and
|
||||
// nonBrowserWindowShutdown() are used for non-browser windows in
|
||||
// macBrowserOverlay
|
||||
function nonBrowserWindowStartup()
|
||||
{
|
||||
function nonBrowserWindowStartup() {
|
||||
// Disable inappropriate commands / submenus
|
||||
var disabledItems = ['Browser:SavePage',
|
||||
'Browser:SendLink', 'cmd_pageSetup', 'cmd_print', 'cmd_find', 'cmd_findAgain',
|
||||
@ -1761,8 +1771,7 @@ function nonBrowserWindowStartup()
|
||||
'View:PageInfo', 'Tasks:InspectPage', 'Browser:ToggleTabView', ];
|
||||
var element;
|
||||
|
||||
for (var id in disabledItems)
|
||||
{
|
||||
for (var id in disabledItems) {
|
||||
element = document.getElementById(disabledItems[id]);
|
||||
if (element)
|
||||
element.setAttribute("disabled", "true");
|
||||
@ -1770,11 +1779,9 @@ function nonBrowserWindowStartup()
|
||||
|
||||
// If no windows are active (i.e. we're the hidden window), disable the close, minimize
|
||||
// and zoom menu commands as well
|
||||
if (window.location.href == "chrome://browser/content/hiddenWindow.xul")
|
||||
{
|
||||
if (window.location.href == "chrome://browser/content/hiddenWindow.xul") {
|
||||
var hiddenWindowDisabledItems = ['cmd_close', 'minimizeWindow', 'zoomWindow'];
|
||||
for (var id in hiddenWindowDisabledItems)
|
||||
{
|
||||
for (var id in hiddenWindowDisabledItems) {
|
||||
element = document.getElementById(hiddenWindowDisabledItems[id]);
|
||||
if (element)
|
||||
element.setAttribute("disabled", "true");
|
||||
@ -1802,12 +1809,12 @@ function nonBrowserWindowStartup()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
setTimeout(nonBrowserWindowDelayedStartup, 0);
|
||||
gDelayedStartupTimeoutId = setTimeout(nonBrowserWindowDelayedStartup, 0);
|
||||
}
|
||||
|
||||
function nonBrowserWindowDelayedStartup()
|
||||
{
|
||||
function nonBrowserWindowDelayedStartup() {
|
||||
gDelayedStartupTimeoutId = null;
|
||||
|
||||
// initialise the offline listener
|
||||
BrowserOffline.init();
|
||||
|
||||
@ -1821,10 +1828,18 @@ function nonBrowserWindowDelayedStartup()
|
||||
// initialize the sync UI
|
||||
gSyncUI.init();
|
||||
#endif
|
||||
|
||||
gStartupRan = true;
|
||||
}
|
||||
|
||||
function nonBrowserWindowShutdown() {
|
||||
// If nonBrowserWindowDelayedStartup hasn't run yet, we have no work to do -
|
||||
// just cancel the pending timeout and return;
|
||||
if (gDelayedStartupTimeoutId) {
|
||||
clearTimeout(gDelayedStartupTimeoutId);
|
||||
return;
|
||||
}
|
||||
|
||||
function nonBrowserWindowShutdown()
|
||||
{
|
||||
BrowserOffline.uninit();
|
||||
|
||||
gPrivateBrowsingUI.uninit();
|
||||
@ -2258,9 +2273,15 @@ function getShortcutOrURI(aURL, aPostDataRef) {
|
||||
} catch (e) {}
|
||||
}
|
||||
|
||||
// encodeURIComponent produces UTF-8, and cannot be used for other charsets.
|
||||
// escape() works in those cases, but it doesn't uri-encode +, @, and /.
|
||||
// Therefore we need to manually replace these ASCII characters by their
|
||||
// encodeURIComponent result, to match the behavior of nsEscape() with
|
||||
// url_XPAlphas
|
||||
var encodedParam = "";
|
||||
if (charset)
|
||||
encodedParam = escape(convertFromUnicode(charset, param));
|
||||
if (charset && charset != "UTF-8")
|
||||
encodedParam = escape(convertFromUnicode(charset, param)).
|
||||
replace(/[+@\/]+/g, encodeURIComponent);
|
||||
else // Default charset is UTF-8
|
||||
encodedParam = encodeURIComponent(param);
|
||||
|
||||
|
@ -1,50 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
# ***** BEGIN LICENSE BLOCK *****
|
||||
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
||||
#
|
||||
# The contents of this file are subject to the Mozilla Public License Version
|
||||
# 1.1 (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
# http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS IS" basis,
|
||||
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
||||
# for the specific language governing rights and limitations under the
|
||||
# License.
|
||||
#
|
||||
# The Original Code is Mozilla.org code.
|
||||
#
|
||||
# The Initial Developer of the Original Code is Asaf Romano
|
||||
# Portions created by the Initial Developer are Copyright (C) 2005
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Asaf Romano <mozilla.mano@sent.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
||||
# in which case the provisions of the GPL or the LGPL are applicable instead
|
||||
# of those above. If you wish to allow use of your version of this file only
|
||||
# under the terms of either the GPL or the LGPL, and not to allow others to
|
||||
# use your version of this file under the terms of the MPL, indicate your
|
||||
# decision by deleting the provisions above and replace them with the notice
|
||||
# and other provisions required by the GPL or the LGPL. If you do not delete
|
||||
# the provisions above, a recipient may use your version of this file under
|
||||
# the terms of any one of the MPL, the GPL or the LGPL.
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
<?xul-overlay href="chrome://browser/content/macBrowserOverlay.xul"?>
|
||||
|
||||
<overlay id="extensionsManagerOverlay"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
|
||||
|
||||
<window id="extensionsManager">
|
||||
|
||||
#include browserMountPoints.inc
|
||||
|
||||
</window>
|
||||
|
||||
</overlay>
|
@ -44,6 +44,8 @@
|
||||
%syncBrandDTD;
|
||||
<!ENTITY % syncKeyDTD SYSTEM "chrome://browser/locale/syncKey.dtd">
|
||||
%syncKeyDTD;
|
||||
<!ENTITY % globalDTD SYSTEM "chrome://global/locale/global.dtd" >
|
||||
%globalDTD;
|
||||
]>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
@ -57,10 +59,10 @@
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<body dir="&locale.dir;">
|
||||
<h1>&syncKey.page.title;</h1>
|
||||
|
||||
<p id="synckey">SYNCKEY</p>
|
||||
<p id="synckey" dir="ltr">SYNCKEY</p>
|
||||
|
||||
<p>&syncKey.page.description;</p>
|
||||
|
||||
|
@ -78,7 +78,6 @@ function GroupItem(listOfEls, options) {
|
||||
this.id = options.id || GroupItems.getNextID();
|
||||
this._isStacked = false;
|
||||
this.expanded = null;
|
||||
this.topChild = null;
|
||||
this.hidden = false;
|
||||
this.fadeAwayUndoButtonDelay = 15000;
|
||||
this.fadeAwayUndoButtonDuration = 300;
|
||||
@ -303,6 +302,7 @@ GroupItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
"tab must be null (if no children) or a TabItem");
|
||||
|
||||
this._activeTab = tab;
|
||||
this.arrange({immediately: true});
|
||||
},
|
||||
|
||||
// -----------
|
||||
@ -350,8 +350,7 @@ GroupItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
// determined by whether the tab is this group's topChild, or
|
||||
// if it doesn't have one, its first child.
|
||||
isTopOfStack: function GroupItem_isTopOfStack(item) {
|
||||
return this.isStacked() && ((this.topChild == item) ||
|
||||
(!this.topChild && this.getChild(0) == item));
|
||||
return this.isStacked() && item == this.getTopChild();
|
||||
},
|
||||
|
||||
// ----------
|
||||
@ -618,7 +617,7 @@ GroupItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
var zIndex = topZIndex;
|
||||
var self = this;
|
||||
this._children.forEach(function(child) {
|
||||
if (child == self.topChild)
|
||||
if (child == self.getTopChild())
|
||||
child.setZ(topZIndex + 1);
|
||||
else {
|
||||
child.setZ(zIndex);
|
||||
@ -1436,11 +1435,12 @@ GroupItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
var self = this;
|
||||
var children = [];
|
||||
|
||||
// ensure this.topChild is the first item in childrenToArrange
|
||||
let topChildPos = childrenToArrange.indexOf(this.topChild);
|
||||
// ensure topChild is the first item in childrenToArrange
|
||||
let topChild = this.getTopChild();
|
||||
let topChildPos = childrenToArrange.indexOf(topChild);
|
||||
if (topChildPos > 0) {
|
||||
childrenToArrange.splice(topChildPos, 1);
|
||||
childrenToArrange.unshift(this.topChild);
|
||||
childrenToArrange.unshift(topChild);
|
||||
}
|
||||
|
||||
childrenToArrange.forEach(function GroupItem__stackArrange_order(child) {
|
||||
@ -1495,7 +1495,6 @@ GroupItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
box.inset(8, 8);
|
||||
arrangeOptions = Utils.extend({}, options, {z: 99999});
|
||||
} else {
|
||||
this.topChild = null;
|
||||
this._isStacked = false;
|
||||
arrangeOptions = Utils.extend({}, options, {
|
||||
columns: this._columns
|
||||
@ -1541,8 +1540,7 @@ GroupItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
var self = this;
|
||||
// ___ we're stacked, and command is held down so expand
|
||||
GroupItems.setActiveGroupItem(self);
|
||||
let activeTab = this.topChild || this.getChildren()[0];
|
||||
UI.setActiveTab(activeTab);
|
||||
UI.setActiveTab(this.getTopChild());
|
||||
|
||||
var startBounds = this.getChild(0).getBounds();
|
||||
var $tray = iQ("<div>").css({
|
||||
@ -1858,13 +1856,14 @@ GroupItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
},
|
||||
|
||||
// ----------
|
||||
// Function: setTopChild
|
||||
// Sets the <Item> that should be displayed on top when in stack mode.
|
||||
setTopChild: function GroupItem_setTopChild(topChild) {
|
||||
this.topChild = topChild;
|
||||
// Function: getTopChild
|
||||
// Gets the <Item> that should be displayed on top when in stack mode.
|
||||
getTopChild: function GroupItem_getTopChild() {
|
||||
if (!this.getChildren().length) {
|
||||
return null;
|
||||
}
|
||||
|
||||
this.arrange({animate: false});
|
||||
// this.arrange calls this.save for us
|
||||
return this.getActiveTab() || this.getChild(0);
|
||||
},
|
||||
|
||||
// ----------
|
||||
|
@ -719,11 +719,6 @@ TabItem.prototype = Utils.extend(new Item(), new Subscribable(), {
|
||||
|
||||
$tab.addClass("front");
|
||||
|
||||
// If we're in a stacked group, make sure we become the
|
||||
// topChild now so that we show the zoom animation correctly.
|
||||
if (this.parent && this.parent.isStacked())
|
||||
this.parent.setTopChild(this);
|
||||
|
||||
let animateZoom = gPrefBranch.getBoolPref("animate_zoom");
|
||||
if (animateZoom) {
|
||||
// The scaleCheat of 2 here is a clever way to speed up the zoom-out
|
||||
@ -1143,9 +1138,15 @@ let TabItems = {
|
||||
_checkHeartbeat: function TabItems__checkHeartbeat() {
|
||||
this._heartbeat = null;
|
||||
|
||||
if (this.isPaintingPaused() || !UI.isIdle)
|
||||
if (this.isPaintingPaused())
|
||||
return;
|
||||
|
||||
// restart the heartbeat to update all waiting tabs once the UI becomes idle
|
||||
if (!UI.isIdle()) {
|
||||
this.startHeartbeat();
|
||||
return;
|
||||
}
|
||||
|
||||
let accumTime = 0;
|
||||
let items = this._tabsWaitingForUpdate.getItems();
|
||||
// Do as many updates as we can fit into a "perceived" amount
|
||||
|
@ -497,9 +497,6 @@ let UI = {
|
||||
|
||||
self.setActiveTab(item);
|
||||
|
||||
if (activeGroupItem && item.parent)
|
||||
activeGroupItem.setTopChild(item);
|
||||
|
||||
self._resize(true);
|
||||
dispatchEvent(event);
|
||||
|
||||
|
@ -74,6 +74,14 @@ var testData = [
|
||||
// Explicitly-defined ISO-8859-1
|
||||
[new bmKeywordData("bmget-escaping2", "http://bmget/?esc=%s&raw=%S&mozcharset=ISO-8859-1", null, "foé"),
|
||||
new keywordResult("http://bmget/?esc=fo%E9&raw=foé", null)],
|
||||
|
||||
// Bug 359809: Test escaping +, /, and @
|
||||
// UTF-8 default
|
||||
[new bmKeywordData("bmget-escaping", "http://bmget/?esc=%s&raw=%S", null, "+/@"),
|
||||
new keywordResult("http://bmget/?esc=%2B%2F%40&raw=+/@", null)],
|
||||
// Explicitly-defined ISO-8859-1
|
||||
[new bmKeywordData("bmget-escaping2", "http://bmget/?esc=%s&raw=%S&mozcharset=ISO-8859-1", null, "+/@"),
|
||||
new keywordResult("http://bmget/?esc=%2B%2F%40&raw=+/@", null)],
|
||||
];
|
||||
|
||||
function test() {
|
||||
|
@ -128,8 +128,10 @@ _BROWSER_FILES = \
|
||||
browser_tabview_bug635696.js \
|
||||
browser_tabview_bug640765.js \
|
||||
browser_tabview_bug641802.js \
|
||||
browser_tabview_bug642793.js \
|
||||
browser_tabview_bug644097.js \
|
||||
browser_tabview_bug645653.js \
|
||||
browser_tabview_bug648882.js \
|
||||
browser_tabview_bug649006.js \
|
||||
browser_tabview_bug649307.js \
|
||||
browser_tabview_bug651311.js \
|
||||
|
@ -0,0 +1,27 @@
|
||||
/* Any copyright is dedicated to the Public Domain.
|
||||
http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
function test() {
|
||||
waitForExplicitFinish();
|
||||
newWindowWithTabView(testTopOfStack, loadTabs);
|
||||
}
|
||||
|
||||
function loadTabs (win) {
|
||||
for (let i = 0; i < 4; i++)
|
||||
win.gBrowser.loadOneTab('about:blank', {inBackground: false});
|
||||
win.gBrowser.selectedTab = win.gBrowser.tabs[2];
|
||||
}
|
||||
|
||||
function testTopOfStack(win) {
|
||||
registerCleanupFunction(function () { win.close(); });
|
||||
let cw = win.TabView.getContentWindow();
|
||||
groupItem = cw.GroupItems.getActiveGroupItem();
|
||||
ok(!groupItem.isStacked(), 'groupItem is not stacked');
|
||||
groupItem.setSize(150, 150);
|
||||
groupItem.setUserSize();
|
||||
ok(groupItem.isStacked(), 'groupItem is now stacked');
|
||||
ok(groupItem.isTopOfStack(groupItem.getChild(2)),
|
||||
'the third tab is on top of stack');
|
||||
finish();
|
||||
}
|
||||
|
@ -0,0 +1,33 @@
|
||||
/* Any copyright is dedicated to the Public Domain.
|
||||
http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
function test() {
|
||||
waitForExplicitFinish();
|
||||
|
||||
newWindowWithTabView(function (win) {
|
||||
registerCleanupFunction(function () win.close());
|
||||
|
||||
let cw = win.TabView.getContentWindow();
|
||||
let tab = win.gBrowser.tabs[0];
|
||||
let tabItem = tab._tabViewTabItem;
|
||||
let isIdle = false;
|
||||
|
||||
// We replace UI.isIdle() here to not rely on setTimeout(). While this
|
||||
// function returns false (busy) we expect no tabItem updates to happen.
|
||||
let busyCount = 5;
|
||||
cw.UI.isIdle = function () {
|
||||
return isIdle = (0 > --busyCount);
|
||||
};
|
||||
|
||||
cw.TabItems.pausePainting();
|
||||
|
||||
tabItem.addSubscriber(tabItem, "updated", function () {
|
||||
tabItem.removeSubscriber(tabItem, "updated");
|
||||
ok(isIdle, "tabItem is updated only when UI is idle");
|
||||
finish();
|
||||
});
|
||||
|
||||
cw.TabItems.update(tab);
|
||||
cw.TabItems.resumePainting();
|
||||
});
|
||||
}
|
@ -121,14 +121,14 @@ function onTabViewWindowLoaded(win) {
|
||||
let stackCenter = children[0].getBounds().center();
|
||||
ok(stackCenter.y < expanderBounds.center().y, "The expander is below the stack.");
|
||||
|
||||
is(group.topChild, children[1], "The top child in the stack is the second tab item");
|
||||
is(group.getTopChild(), children[1], "The top child in the stack is the second tab item");
|
||||
let topChildzIndex = children[1].zIndex;
|
||||
// the second tab item should have the largest z-index.
|
||||
// only check the first 6 tabs as the stack only contains 6 tab items.
|
||||
for (let i = 0; i < 6; i++) {
|
||||
if (i != 1)
|
||||
ok(children[i].zIndex < topChildzIndex,
|
||||
"The child[" + i + "] has smaller zIndex than second dhild");
|
||||
"The child[" + i + "] has smaller zIndex than second child");
|
||||
}
|
||||
|
||||
// okay, expand this group one last time
|
||||
@ -160,7 +160,7 @@ function onTabViewWindowLoaded(win) {
|
||||
let stackCenter = children[0].getBounds().center();
|
||||
ok(stackCenter.y < expanderBounds.center().y, "The expander is below the stack.");
|
||||
|
||||
is(group.topChild, children[1],
|
||||
is(group.getTopChild(), children[1],
|
||||
"The top child in the stack is still the second tab item");
|
||||
let topChildzIndex = children[1].zIndex;
|
||||
// the second tab item should have the largest z-index.
|
||||
|
@ -2,7 +2,6 @@ browser.jar:
|
||||
% content browser %content/browser/ contentaccessible=yes
|
||||
#ifdef XP_MACOSX
|
||||
% overlay chrome://mozapps/content/downloads/downloads.xul chrome://browser/content/downloadManagerOverlay.xul
|
||||
% overlay chrome://mozapps/content/extensions/extensions.xul chrome://browser/content/extensionsManagerOverlay.xul
|
||||
% overlay chrome://global/content/console.xul chrome://browser/content/jsConsoleOverlay.xul
|
||||
% overlay chrome://mozapps/content/update/updates.xul chrome://browser/content/softwareUpdateOverlay.xul
|
||||
#endif
|
||||
@ -79,7 +78,6 @@ browser.jar:
|
||||
#ifdef XP_MACOSX
|
||||
* content/browser/macBrowserOverlay.xul (content/macBrowserOverlay.xul)
|
||||
* content/browser/downloadManagerOverlay.xul (content/downloadManagerOverlay.xul)
|
||||
* content/browser/extensionsManagerOverlay.xul (content/extensionsManagerOverlay.xul)
|
||||
* content/browser/jsConsoleOverlay.xul (content/jsConsoleOverlay.xul)
|
||||
* content/browser/softwareUpdateOverlay.xul (content/softwareUpdateOverlay.xul)
|
||||
#endif
|
||||
|
@ -62,7 +62,6 @@ XPCOMUtils.defineLazyGetter(this, "PlacesUtils", function() {
|
||||
return PlacesUtils;
|
||||
});
|
||||
|
||||
const PREF_EM_NEW_ADDONS_LIST = "extensions.newAddons";
|
||||
const PREF_PLUGINS_NOTIFYUSER = "plugins.update.notifyUser";
|
||||
const PREF_PLUGINS_UPDATEURL = "plugins.update.url";
|
||||
|
||||
@ -397,24 +396,6 @@ BrowserGlue.prototype = {
|
||||
if (Services.prefs.prefHasUserValue("app.update.postupdate"))
|
||||
this._showUpdateNotification();
|
||||
|
||||
// If new add-ons were installed during startup open the add-ons manager.
|
||||
if (Services.prefs.prefHasUserValue(PREF_EM_NEW_ADDONS_LIST)) {
|
||||
var args = Cc["@mozilla.org/supports-array;1"].
|
||||
createInstance(Ci.nsISupportsArray);
|
||||
var str = Cc["@mozilla.org/supports-string;1"].
|
||||
createInstance(Ci.nsISupportsString);
|
||||
str.data = "";
|
||||
args.AppendElement(str);
|
||||
var str = Cc["@mozilla.org/supports-string;1"].
|
||||
createInstance(Ci.nsISupportsString);
|
||||
str.data = Services.prefs.getCharPref(PREF_EM_NEW_ADDONS_LIST);
|
||||
args.AppendElement(str);
|
||||
const EMURL = "chrome://mozapps/content/extensions/extensions.xul";
|
||||
const EMFEATURES = "chrome,menubar,extra-chrome,toolbar,dialog=no,resizable";
|
||||
Services.ww.openWindow(null, EMURL, "_blank", EMFEATURES, args);
|
||||
Services.prefs.clearUserPref(PREF_EM_NEW_ADDONS_LIST);
|
||||
}
|
||||
|
||||
// Load the "more info" page for a locked places.sqlite
|
||||
// This property is set earlier by places-database-locked topic.
|
||||
if (this._isPlacesDatabaseLocked) {
|
||||
|
@ -203,10 +203,6 @@ PlacesController.prototype = {
|
||||
!PlacesUtils.nodeIsLivemarkItem(selectedNode))
|
||||
return true;
|
||||
return false;
|
||||
case "placesCmd_reloadMicrosummary":
|
||||
var selectedNode = this._view.selectedNode;
|
||||
return selectedNode && PlacesUtils.nodeIsBookmark(selectedNode) &&
|
||||
PlacesUtils.microsummaries.hasMicrosummary(selectedNode.itemId);
|
||||
case "placesCmd_reload":
|
||||
// Livemark containers
|
||||
var selectedNode = this._view.selectedNode;
|
||||
@ -293,9 +289,6 @@ PlacesController.prototype = {
|
||||
case "placesCmd_reload":
|
||||
this.reloadSelectedLivemark();
|
||||
break;
|
||||
case "placesCmd_reloadMicrosummary":
|
||||
this.reloadSelectedMicrosummary();
|
||||
break;
|
||||
case "placesCmd_sortBy:name":
|
||||
this.sortFolderByName();
|
||||
break;
|
||||
@ -505,9 +498,6 @@ PlacesController.prototype = {
|
||||
if (PlacesUtils.nodeIsBookmark(node)) {
|
||||
nodeData["bookmark"] = true;
|
||||
PlacesUtils.nodeIsTagQuery(node.parent)
|
||||
var mss = PlacesUtils.microsummaries;
|
||||
if (mss.hasMicrosummary(node.itemId))
|
||||
nodeData["microsummary"] = true;
|
||||
|
||||
var parentNode = node.parent;
|
||||
if (parentNode) {
|
||||
@ -741,16 +731,6 @@ PlacesController.prototype = {
|
||||
PlacesUtils.livemarks.reloadLivemarkFolder(selectedNode.itemId);
|
||||
},
|
||||
|
||||
/**
|
||||
* Reload the microsummary associated with the selection
|
||||
*/
|
||||
reloadSelectedMicrosummary: function PC_reloadSelectedMicrosummary() {
|
||||
var selectedNode = this._view.selectedNode;
|
||||
var mss = PlacesUtils.microsummaries;
|
||||
if (mss.hasMicrosummary(selectedNode.itemId))
|
||||
mss.refreshMicrosummary(selectedNode.itemId);
|
||||
},
|
||||
|
||||
/**
|
||||
* Opens the links in the selected folder, or the selected links in new tabs.
|
||||
*/
|
||||
@ -1574,7 +1554,6 @@ function goUpdatePlacesCommands() {
|
||||
updatePlacesCommand("placesCmd_show:info");
|
||||
updatePlacesCommand("placesCmd_moveBookmarks");
|
||||
updatePlacesCommand("placesCmd_reload");
|
||||
updatePlacesCommand("placesCmd_reloadMicrosummary");
|
||||
updatePlacesCommand("placesCmd_sortBy:name");
|
||||
updatePlacesCommand("placesCmd_cut");
|
||||
updatePlacesCommand("placesCmd_copy");
|
||||
|
@ -36,7 +36,6 @@
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
const LAST_USED_ANNO = "bookmarkPropertiesDialog/folderLastUsed";
|
||||
const STATIC_TITLE_ANNO = "bookmarks/staticTitle";
|
||||
const MAX_FOLDER_ITEM_IN_MENU_LIST = 5;
|
||||
|
||||
var gEditItemOverlay = {
|
||||
@ -49,7 +48,6 @@ var gEditItemOverlay = {
|
||||
_multiEdit: false,
|
||||
_itemType: -1,
|
||||
_readOnly: false,
|
||||
_microsummaries: null,
|
||||
_hiddenRows: [],
|
||||
_observersAdded: false,
|
||||
_staticFoldersListBuilt: false,
|
||||
@ -367,8 +365,7 @@ var gEditItemOverlay = {
|
||||
},
|
||||
|
||||
QueryInterface: function EIO_QueryInterface(aIID) {
|
||||
if (aIID.equals(Ci.nsIMicrosummaryObserver) ||
|
||||
aIID.equals(Ci.nsIDOMEventListener) ||
|
||||
if (aIID.equals(Ci.nsIDOMEventListener) ||
|
||||
aIID.equals(Ci.nsINavBookmarkObserver) ||
|
||||
aIID.equals(Ci.nsISupports))
|
||||
return this;
|
||||
@ -380,108 +377,16 @@ var gEditItemOverlay = {
|
||||
return document.getElementById("editBMPanel_" + aID);
|
||||
},
|
||||
|
||||
_createMicrosummaryMenuItem:
|
||||
function EIO__createMicrosummaryMenuItem(aMicrosummary) {
|
||||
var menuItem = document.createElement("menuitem");
|
||||
|
||||
// Store a reference to the microsummary in the menu item, so we know
|
||||
// which microsummary this menu item represents when it's time to
|
||||
// save changes or load its content.
|
||||
menuItem.microsummary = aMicrosummary;
|
||||
|
||||
// Content may have to be generated asynchronously; we don't necessarily
|
||||
// have it now. If we do, great; otherwise, fall back to the generator
|
||||
// name, then the URI, and we trigger a microsummary content update. Once
|
||||
// the update completes, the microsummary will notify our observer to
|
||||
// update the corresponding menu-item.
|
||||
// XXX Instead of just showing the generator name or (heaven forbid)
|
||||
// its URI when we don't have content, we should tell the user that
|
||||
// we're loading the microsummary, perhaps with some throbbing to let
|
||||
// her know it is in progress.
|
||||
if (aMicrosummary.content)
|
||||
menuItem.setAttribute("label", aMicrosummary.content);
|
||||
else {
|
||||
menuItem.setAttribute("label", aMicrosummary.generator.name ||
|
||||
aMicrosummary.generator.uri.spec);
|
||||
aMicrosummary.update();
|
||||
}
|
||||
|
||||
return menuItem;
|
||||
},
|
||||
|
||||
_getItemStaticTitle: function EIO__getItemStaticTitle() {
|
||||
if (this._itemId == -1)
|
||||
return PlacesUtils.history.getPageTitle(this._uri);
|
||||
|
||||
const annos = PlacesUtils.annotations;
|
||||
if (annos.itemHasAnnotation(this._itemId, STATIC_TITLE_ANNO))
|
||||
return annos.getItemAnnotation(this._itemId, STATIC_TITLE_ANNO);
|
||||
|
||||
return PlacesUtils.bookmarks.getItemTitle(this._itemId);
|
||||
},
|
||||
|
||||
_initNamePicker: function EIO_initNamePicker() {
|
||||
var userEnteredNameField = this._element("userEnteredName");
|
||||
var namePicker = this._element("namePicker");
|
||||
var droppable = false;
|
||||
|
||||
userEnteredNameField.label = this._getItemStaticTitle();
|
||||
|
||||
// clean up old entries
|
||||
var menupopup = namePicker.menupopup;
|
||||
while (menupopup.childNodes.length > 2)
|
||||
menupopup.removeChild(menupopup.lastChild);
|
||||
|
||||
if (this._microsummaries) {
|
||||
this._microsummaries.removeObserver(this);
|
||||
this._microsummaries = null;
|
||||
}
|
||||
|
||||
var itemToSelect = userEnteredNameField;
|
||||
try {
|
||||
if (this._itemId != -1 &&
|
||||
this._itemType == Ci.nsINavBookmarksService.TYPE_BOOKMARK &&
|
||||
!this._readOnly)
|
||||
this._microsummaries = PlacesUtils.microsummaries
|
||||
.getMicrosummaries(this._uri, -1);
|
||||
}
|
||||
catch(ex) {
|
||||
// getMicrosummaries will throw an exception in at least two cases:
|
||||
// 1. the bookmarked URI contains a scheme that the service won't
|
||||
// download for security reasons (currently it only handles http,
|
||||
// https, and file);
|
||||
// 2. the page to which the URI refers isn't HTML or XML (the only two
|
||||
// content types the service knows how to summarize).
|
||||
this._microsummaries = null;
|
||||
}
|
||||
|
||||
if (this._microsummaries) {
|
||||
var enumerator = this._microsummaries.Enumerate();
|
||||
|
||||
if (enumerator.hasMoreElements()) {
|
||||
// Show the drop marker if there are microsummaries
|
||||
droppable = true;
|
||||
while (enumerator.hasMoreElements()) {
|
||||
var microsummary = enumerator.getNext()
|
||||
.QueryInterface(Ci.nsIMicrosummary);
|
||||
var menuItem = this._createMicrosummaryMenuItem(microsummary);
|
||||
if (PlacesUtils.microsummaries
|
||||
.isMicrosummary(this._itemId, microsummary))
|
||||
itemToSelect = menuItem;
|
||||
|
||||
menupopup.appendChild(menuItem);
|
||||
}
|
||||
}
|
||||
|
||||
this._microsummaries.addObserver(this);
|
||||
}
|
||||
|
||||
if (namePicker.selectedItem == itemToSelect)
|
||||
namePicker.value = itemToSelect.label;
|
||||
else
|
||||
namePicker.selectedItem = itemToSelect;
|
||||
|
||||
namePicker.setAttribute("droppable", droppable);
|
||||
namePicker.value = this._getItemStaticTitle();
|
||||
namePicker.readOnly = this._readOnly;
|
||||
|
||||
// clear the undo stack
|
||||
@ -490,40 +395,6 @@ var gEditItemOverlay = {
|
||||
editor.transactionManager.clear();
|
||||
},
|
||||
|
||||
// nsIMicrosummaryObserver
|
||||
onContentLoaded: function EIO_onContentLoaded(aMicrosummary) {
|
||||
var namePicker = this._element("namePicker");
|
||||
var childNodes = namePicker.menupopup.childNodes;
|
||||
|
||||
// 0: user-entered item; 1: separator
|
||||
for (var i = 2; i < childNodes.length; i++) {
|
||||
if (childNodes[i].microsummary == aMicrosummary) {
|
||||
var newLabel = aMicrosummary.content;
|
||||
// XXXmano: non-editable menulist would do this for us, see bug 360220
|
||||
// We should fix editable-menulists to set the DOMAttrModified handler
|
||||
// as well.
|
||||
//
|
||||
// Also note the order importance: if the label of the menu-item is
|
||||
// set to something different than the menulist's current value,
|
||||
// the menulist no longer has selectedItem set
|
||||
if (namePicker.selectedItem == childNodes[i])
|
||||
namePicker.value = newLabel;
|
||||
|
||||
childNodes[i].label = newLabel;
|
||||
return;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
onElementAppended: function EIO_onElementAppended(aMicrosummary) {
|
||||
var namePicker = this._element("namePicker");
|
||||
namePicker.menupopup
|
||||
.appendChild(this._createMicrosummaryMenuItem(aMicrosummary));
|
||||
|
||||
// Make sure the drop-marker is shown
|
||||
namePicker.setAttribute("droppable", "true");
|
||||
},
|
||||
|
||||
uninitPanel: function EIO_uninitPanel(aHideCollapsibleElements) {
|
||||
if (aHideCollapsibleElements) {
|
||||
// hide the folder tree if it was previously visible
|
||||
@ -543,10 +414,7 @@ var gEditItemOverlay = {
|
||||
|
||||
this._observersAdded = false;
|
||||
}
|
||||
if (this._microsummaries) {
|
||||
this._microsummaries.removeObserver(this);
|
||||
this._microsummaries = null;
|
||||
}
|
||||
|
||||
this._itemId = -1;
|
||||
this._uri = null;
|
||||
this._uris = [];
|
||||
@ -673,11 +541,6 @@ var gEditItemOverlay = {
|
||||
return false;
|
||||
},
|
||||
|
||||
onNamePickerInput: function EIO_onNamePickerInput() {
|
||||
var title = this._element("namePicker").value;
|
||||
this._element("userEnteredName").label = title;
|
||||
},
|
||||
|
||||
onNamePickerChange: function EIO_onNamePickerChange() {
|
||||
if (this._itemId == -1)
|
||||
return;
|
||||
@ -687,7 +550,7 @@ var gEditItemOverlay = {
|
||||
const ptm = PlacesUIUtils.ptm;
|
||||
|
||||
// Here we update either the item title or its cached static title
|
||||
var newTitle = this._element("userEnteredName").label;
|
||||
var newTitle = namePicker.value;
|
||||
if (!newTitle &&
|
||||
PlacesUtils.bookmarks.getFolderIdForItem(this._itemId) == PlacesUtils.tagsFolderId) {
|
||||
// We don't allow setting an empty title for a tag, restore the old one.
|
||||
@ -695,34 +558,9 @@ var gEditItemOverlay = {
|
||||
}
|
||||
else if (this._getItemStaticTitle() != newTitle) {
|
||||
this._mayUpdateFirstEditField("namePicker");
|
||||
if (PlacesUtils.microsummaries.hasMicrosummary(this._itemId)) {
|
||||
// Note: this implicitly also takes care of the microsummary->static
|
||||
// title case, the removeMicorosummary method in the service will set
|
||||
// the item-title to the value of this annotation.
|
||||
//
|
||||
// XXXmano: use a transaction
|
||||
PlacesUtils.setAnnotationsForItem(this._itemId,
|
||||
[{name: STATIC_TITLE_ANNO,
|
||||
value: newTitle}]);
|
||||
}
|
||||
else
|
||||
txns.push(ptm.editItemTitle(this._itemId, newTitle));
|
||||
}
|
||||
|
||||
var newMicrosummary = namePicker.selectedItem.microsummary;
|
||||
|
||||
// Only add a microsummary update to the transaction if the microsummary
|
||||
// has actually changed, i.e. the user selected no microsummary, but the
|
||||
// bookmark previously had one, or the user selected a microsummary which
|
||||
// is not the one the bookmark previously had
|
||||
if ((newMicrosummary == null &&
|
||||
PlacesUtils.microsummaries.hasMicrosummary(this._itemId)) ||
|
||||
(newMicrosummary != null &&
|
||||
!PlacesUtils.microsummaries
|
||||
.isMicrosummary(this._itemId, newMicrosummary))) {
|
||||
txns.push(ptm.editBookmarkMicrosummary(this._itemId, newMicrosummary));
|
||||
}
|
||||
|
||||
var aggregate = ptm.aggregateTransactions("Edit Item Title", txns);
|
||||
ptm.doTransaction(aggregate);
|
||||
},
|
||||
@ -1121,21 +959,12 @@ var gEditItemOverlay = {
|
||||
|
||||
switch (aProperty) {
|
||||
case "title":
|
||||
if (PlacesUtils.annotations.itemHasAnnotation(this._itemId,
|
||||
STATIC_TITLE_ANNO))
|
||||
return; // onContentLoaded updates microsummary-items
|
||||
|
||||
var userEnteredNameField = this._element("userEnteredName");
|
||||
if (userEnteredNameField.value != aValue) {
|
||||
userEnteredNameField.value = aValue;
|
||||
var namePicker = this._element("namePicker");
|
||||
if (namePicker.selectedItem == userEnteredNameField) {
|
||||
namePicker.label = aValue;
|
||||
|
||||
if (namePicker.value != aValue) {
|
||||
namePicker.value = aValue;
|
||||
// clear undo stack
|
||||
namePicker.editor.transactionManager.clear();
|
||||
}
|
||||
}
|
||||
break;
|
||||
case "uri":
|
||||
var locationField = this._element("locationField");
|
||||
@ -1144,7 +973,7 @@ var gEditItemOverlay = {
|
||||
getService(Ci.nsIIOService).
|
||||
newURI(aValue, null, null);
|
||||
this._initTextField("locationField", this._uri.spec);
|
||||
this._initNamePicker(); // for microsummaries
|
||||
this._initNamePicker();
|
||||
this._initTextField("tagsField",
|
||||
PlacesUtils.tagging
|
||||
.getTagsForURI(this._uri).join(", "),
|
||||
|
@ -65,22 +65,9 @@
|
||||
accesskey="&editBookmarkOverlay.name.accesskey;"
|
||||
control="editBMPanel_namePicker"
|
||||
observes="paneElementsBroadcaster"/>
|
||||
<menulist id="editBMPanel_namePicker"
|
||||
flex="1"
|
||||
editable="true"
|
||||
droppable="false"
|
||||
oninput="gEditItemOverlay.onNamePickerInput();"
|
||||
<textbox id="editBMPanel_namePicker"
|
||||
onblur="gEditItemOverlay.onNamePickerChange();"
|
||||
oncommand="gEditItemOverlay.onNamePickerChange();"
|
||||
observes="paneElementsBroadcaster">
|
||||
<menupopup>
|
||||
<menuitem id="editBMPanel_userEnteredName"/>
|
||||
<menuitem disabled="true">
|
||||
<menuseparator flex="1"/>
|
||||
<label value="&editBookmarkOverlay.liveTitlesSeparator.label;"/>
|
||||
</menuitem>
|
||||
</menupopup>
|
||||
</menulist>
|
||||
observes="paneElementsBroadcaster"/>
|
||||
</row>
|
||||
|
||||
<row align="center" id="editBMPanel_locationRow">
|
||||
|
@ -101,8 +101,6 @@
|
||||
observes="placesCmd_show:info"/>
|
||||
<command id="placesCmd_reload"
|
||||
oncommand="goDoPlacesCommand('placesCmd_reload');"/>
|
||||
<command id="placesCmd_reloadMicrosummary"
|
||||
oncommand="goDoPlacesCommand('placesCmd_reloadMicrosummary');"/>
|
||||
<command id="placesCmd_sortBy:name"
|
||||
oncommand="goDoPlacesCommand('placesCmd_sortBy:name');"/>
|
||||
<command id="placesCmd_moveBookmarks"
|
||||
@ -239,12 +237,6 @@
|
||||
accesskey="&cmd.reloadLivebookmark.accesskey;"
|
||||
closemenu="single"
|
||||
selection="livemark/feedURI"/>
|
||||
<menuitem id="placesContext_reloadMicrosummary"
|
||||
command="placesCmd_reloadMicrosummary"
|
||||
label="&cmd.reloadMicrosummary.label;"
|
||||
accesskey="&cmd.reloadMicrosummary.accesskey;"
|
||||
closemenu="single"
|
||||
selection="microsummary"/>
|
||||
<menuitem id="placesContext_sortBy:name"
|
||||
command="placesCmd_sortBy:name"
|
||||
label="&cmd.sortby_name.label;"
|
||||
|
@ -320,8 +320,8 @@ var PlacesUIUtils = {
|
||||
function PUIU__reportDeprecatedAddBookmarkMethod() {
|
||||
// Removes "PUIU_".
|
||||
let oldFuncName = arguments.callee.caller.name.slice(5);
|
||||
Cu.reportError(oldFuncName + " is deprecated and will be removed in a \
|
||||
future release. Use showBookmarkDialog instead");
|
||||
Cu.reportError(oldFuncName + " is deprecated and will be removed in a " +
|
||||
"future release. Use showBookmarkDialog instead.");
|
||||
},
|
||||
|
||||
/**
|
||||
@ -810,16 +810,16 @@ var PlacesUIUtils = {
|
||||
|
||||
// If a view wasn't expected, the method should have got a window.
|
||||
if (aView === null) {
|
||||
Components.utils.reportError("The api has changed. A window should be \
|
||||
passed to " + caller.name + ". Not \
|
||||
passing a window will throw in a future \
|
||||
release.");
|
||||
Components.utils.reportError("The api has changed. A window should be " +
|
||||
"passed to " + caller.name + ". Not " +
|
||||
"passing a window will throw in a future " +
|
||||
"release.");
|
||||
}
|
||||
else {
|
||||
Components.utils.reportError("The api has changed. A places view \
|
||||
should be passed to " + caller.name + ". \
|
||||
Not passing a view will throw in a future \
|
||||
release.");
|
||||
Components.utils.reportError("The api has changed. A places view " +
|
||||
"should be passed to " + caller.name + ". " +
|
||||
"Not passing a view will throw in a future " +
|
||||
"release.");
|
||||
}
|
||||
|
||||
// This could certainly break in some edge cases (like bug 562998), but
|
||||
@ -1324,9 +1324,6 @@ XPCOMUtils.defineLazyGetter(PlacesUIUtils, "ptm", function() {
|
||||
editLivemarkFeedURI: function(aLivemarkId, aFeedURI)
|
||||
new PlacesEditLivemarkFeedURITransaction(aLivemarkId, aFeedURI),
|
||||
|
||||
editBookmarkMicrosummary: function(aItemId, aNewMicrosummary)
|
||||
new PlacesEditBookmarkMicrosummaryTransaction(aItemId, aNewMicrosummary),
|
||||
|
||||
editItemDateAdded: function(aItemId, aNewDateAdded)
|
||||
new PlacesEditItemDateAddedTransaction(aItemId, aNewDateAdded),
|
||||
|
||||
|
@ -313,7 +313,6 @@ gTests.push({
|
||||
this._itemId = this.window.gEditItemOverlay._itemId;
|
||||
// Change folder name
|
||||
var namePicker = this.window.document.getElementById("editBMPanel_namePicker");
|
||||
var userEnteredName = this.window.document.getElementById("editBMPanel_userEnteredName");
|
||||
var self = this;
|
||||
|
||||
this.window.addEventListener("unload", function(event) {
|
||||
@ -324,7 +323,6 @@ gTests.push({
|
||||
}, false);
|
||||
|
||||
namePicker.value = "n";
|
||||
userEnteredName.label = "n";
|
||||
info("About to focus the namePicker field");
|
||||
namePicker.focus();
|
||||
EventUtils.synthesizeKey("VK_RETURN", {}, this.window);
|
||||
|
@ -19,10 +19,6 @@
|
||||
<DL><p>
|
||||
<DT><A HREF="http://test/post" ADD_DATE="1177375336" LAST_MODIFIED="1177375423" SHORTCUTURL="test" WEB_PANEL="true" POST_DATA="hidden1%3Dbar&text1%3D%25s" LAST_CHARSET="ISO-8859-1" ID="rdf:#$pYFe7">test post keyword</A>
|
||||
<DD>item description
|
||||
<!-- XXX Bug 380468
|
||||
<DT><A HREF="http://test/micsum" ADD_DATE="1177375377" LAST_MODIFIED="1177541023" LAST_CHARSET="ISO-8859-1" MICSUM_GEN_URI="urn:source:http://dietrich.ganx4.com/mozilla/test-microsummary.xml" MICSUM_EXPIRATION="1177542823620" GENERATED_TITLE="id:462fd9a2e5b66" ID="rdf:#$qYFe7">test microsummary</A>
|
||||
<DD>test microsummary
|
||||
-->
|
||||
</DL>
|
||||
<DT><H3 UNFILED_BOOKMARKS_FOLDER="true">Unsorted Bookmarks</H3>
|
||||
<DL><p>
|
||||
|
@ -223,24 +223,6 @@ function testCanonicalBookmarks() {
|
||||
PlacesUtils.annotations.getItemAnnotation(testBookmark1.itemId,
|
||||
DESCRIPTION_ANNO));
|
||||
|
||||
/*
|
||||
// XXX Bug 380468
|
||||
// test bookmark 2
|
||||
var testBookmark2 = testFolder.getChild(1);
|
||||
// url
|
||||
do_check_eq("http://test/micsum", testBookmark2.uri);
|
||||
// title
|
||||
do_check_eq("test microsummary", testBookmark2.title);
|
||||
// check that it's a microsummary
|
||||
var micsum = mssvc.getMicrosummary(testBookmark2.itemId);
|
||||
if (!micsum)
|
||||
do_throw("Could not import microsummary");
|
||||
// check generator uri
|
||||
var generator = micsum.generator;
|
||||
do_check_eq("urn:source:http://dietrich.ganx4.com/mozilla/test-microsummary.xml", generator.uri.spec);
|
||||
// expiration and generated title can change, so don't test them
|
||||
*/
|
||||
|
||||
// clean up
|
||||
testFolder.containerOpen = false;
|
||||
rootNode.containerOpen = false;
|
||||
|
@ -71,13 +71,6 @@ try {
|
||||
do_throw("Could not get favicon service\n");
|
||||
}
|
||||
|
||||
// Get microsummary service
|
||||
try {
|
||||
var mssvc = Cc["@mozilla.org/microsummary/service;1"].getService(Ci.nsIMicrosummaryService);
|
||||
} catch(ex) {
|
||||
do_throw("Could not get microsummary service\n");
|
||||
}
|
||||
|
||||
// Get io service
|
||||
try {
|
||||
var iosvc = Cc["@mozilla.org/network/io-service;1"].getService(Ci.nsIIOService);
|
||||
@ -266,23 +259,6 @@ function testCanonicalBookmarks(aFolder) {
|
||||
annosvc.getItemAnnotation(testBookmark1.itemId,
|
||||
DESCRIPTION_ANNO));
|
||||
|
||||
/*
|
||||
// XXX Bug 380468
|
||||
// test bookmark 2
|
||||
var testBookmark2 = testFolder.getChild(1);
|
||||
// url
|
||||
do_check_eq("http://test/micsum", testBookmark2.uri);
|
||||
// title
|
||||
do_check_eq("test microsummary", testBookmark2.title);
|
||||
// check that it's a microsummary
|
||||
var micsum = mssvc.getMicrosummary(testBookmark2.itemId);
|
||||
if (!micsum)
|
||||
do_throw("Could not import microsummary");
|
||||
// check generator uri
|
||||
var generator = micsum.generator;
|
||||
do_check_eq("urn:source:http://dietrich.ganx4.com/mozilla/test-microsummary.xml", generator.uri.spec);
|
||||
// expiration and generated title can change, so don't test them
|
||||
*/
|
||||
// clean up
|
||||
testFolder.containerOpen = false;
|
||||
rootNode.containerOpen = false;
|
||||
|
@ -40,7 +40,6 @@
|
||||
|
||||
var bmsvc = PlacesUtils.bookmarks;
|
||||
var lmsvc = PlacesUtils.livemarks;
|
||||
var mss = PlacesUtils.microsummaries;
|
||||
var ptSvc = PlacesUIUtils.ptm;
|
||||
var tagssvc = PlacesUtils.tagging;
|
||||
var annosvc = PlacesUtils.annotations;
|
||||
@ -580,22 +579,6 @@ function run_test() {
|
||||
do_check_eq(1, bmsvc.getItemIndex(b2));
|
||||
do_check_eq(2, bmsvc.getItemIndex(b3));
|
||||
|
||||
// editBookmarkMicrosummary
|
||||
var tmpMs = mss.createMicrosummary(uri("http://testmicro.com"),
|
||||
uri("http://dietrich.ganx4.com/mozilla/test-microsummary.xml"));
|
||||
ptSvc.doTransaction(
|
||||
ptSvc.createItem(uri("http://dietrich.ganx4.com/mozilla/test-microsummary-content.php"),
|
||||
root, -1, "micro test", null, null, null));
|
||||
var bId = (bmsvc.getBookmarkIdsForURI(uri("http://dietrich.ganx4.com/mozilla/test-microsummary-content.php")))[0];
|
||||
do_check_true(!mss.hasMicrosummary(bId));
|
||||
var txn18 = ptSvc.editBookmarkMicrosummary(bId, tmpMs);
|
||||
txn18.doTransaction();
|
||||
do_check_eq(observer._itemChangedId, bId);
|
||||
do_check_true(mss.hasMicrosummary(bId));
|
||||
txn18.undoTransaction();
|
||||
do_check_eq(observer._itemChangedId, bId);
|
||||
do_check_true(!mss.hasMicrosummary(bId));
|
||||
|
||||
// Testing edit Post Data
|
||||
const POST_DATA_ANNO = "bookmarkProperties/POSTData";
|
||||
var postData = "foo";
|
||||
|
@ -97,6 +97,15 @@ function done() {
|
||||
Services.prefs.clearUserPref("browser.sessionstore.resume_from_crash");
|
||||
} catch (e) {}
|
||||
|
||||
// Enumerate windows and close everything but our primary window. We can't
|
||||
// use waitForFocus() because apparently it's buggy. See bug 599253.
|
||||
let windowsEnum = Services.wm.getEnumerator("navigator:browser");
|
||||
while (windowsEnum.hasMoreElements()) {
|
||||
let currentWindow = windowsEnum.getNext();
|
||||
if (currentWindow != window)
|
||||
currentWindow.close();
|
||||
}
|
||||
|
||||
ss.setBrowserState(stateBackup);
|
||||
executeSoon(finish);
|
||||
}
|
||||
|
@ -231,31 +231,6 @@ function (aSearchURL)
|
||||
return 0;
|
||||
}
|
||||
|
||||
nsSidebar.prototype.addMicrosummaryGenerator =
|
||||
function (generatorURL)
|
||||
{
|
||||
debug("addMicrosummaryGenerator(" + generatorURL + ")");
|
||||
|
||||
if (!/^https?:/i.test(generatorURL))
|
||||
return;
|
||||
|
||||
var stringBundle = srGetStrBundle("chrome://browser/locale/sidebar/sidebar.properties");
|
||||
var titleMessage = stringBundle.GetStringFromName("addMicsumGenConfirmTitle");
|
||||
var dialogMessage = stringBundle.formatStringFromName("addMicsumGenConfirmText", [generatorURL], 1);
|
||||
|
||||
if (!this.promptService.confirm(null, titleMessage, dialogMessage))
|
||||
return;
|
||||
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"].
|
||||
getService(Components.interfaces.nsIIOService);
|
||||
var generatorURI = ioService.newURI(generatorURL, null, null);
|
||||
|
||||
var microsummaryService = Components.classes["@mozilla.org/microsummary/service;1"].
|
||||
getService(Components.interfaces.nsIMicrosummaryService);
|
||||
if (microsummaryService)
|
||||
microsummaryService.addGenerator(generatorURI);
|
||||
}
|
||||
|
||||
// property of nsIClassInfo
|
||||
nsSidebar.prototype.flags = nsIClassInfo.DOM_OBJECT;
|
||||
|
||||
|
@ -391,6 +391,7 @@
|
||||
@BINPATH@/components/nsSafebrowsingApplication.manifest
|
||||
@BINPATH@/components/nsSafebrowsingApplication.js
|
||||
@BINPATH@/components/nsURLClassifier.manifest
|
||||
@BINPATH@/components/nsUrlClassifierHashCompleter.js
|
||||
@BINPATH@/components/nsUrlClassifierListManager.js
|
||||
@BINPATH@/components/nsUrlClassifierLib.js
|
||||
@BINPATH@/components/url-classifier.xpt
|
||||
|
@ -77,6 +77,7 @@ components/xmlextras.xpt
|
||||
components/xpcom.xpt
|
||||
components/xpti.dat
|
||||
components/xptitemp.dat
|
||||
components/nsMicrosummaryService.js
|
||||
defaults/pref/all.js
|
||||
defaults/pref/bug259708.js
|
||||
defaults/pref/bug307259.js
|
||||
@ -875,7 +876,6 @@ xpicleanup@BIN_SUFFIX@
|
||||
components/nsLoginInfo.js
|
||||
components/nsLoginManager.js
|
||||
components/nsLoginManagerPrompter.js
|
||||
components/nsMicrosummaryService.js
|
||||
components/nsPlacesAutoComplete.js
|
||||
components/nsPlacesDBFlush.js
|
||||
components/nsPlacesExpiration.js
|
||||
|
@ -104,7 +104,7 @@ can reach it easily. -->
|
||||
<!ENTITY subscribeToPageMenuitem.label "Subscribe to This Page…">
|
||||
<!ENTITY addCurPagesCmd.label "Bookmark All Tabs…">
|
||||
<!ENTITY showAllBookmarks2.label "Show All Bookmarks">
|
||||
<!ENTITY bookmarkAllCmd.label "Bookmark All Tabs…">
|
||||
<!ENTITY unsortedBookmarksCmd.label "Unsorted Bookmarks">
|
||||
<!ENTITY bookmarksToolbarChevron.tooltip "Show more bookmarks">
|
||||
|
||||
<!ENTITY backCmd.label "Back">
|
||||
|
@ -6,7 +6,6 @@
|
||||
<!ENTITY editBookmarkOverlay.feedLocation.accesskey "F">
|
||||
<!ENTITY editBookmarkOverlay.siteLocation.label "Site Location:">
|
||||
<!ENTITY editBookmarkOverlay.siteLocation.accesskey "S">
|
||||
<!ENTITY editBookmarkOverlay.liveTitlesSeparator.label "Live Titles">
|
||||
<!ENTITY editBookmarkOverlay.folder.label "Folder:">
|
||||
<!ENTITY editBookmarkOverlay.foldersExpanderDown.tooltip "Show all the bookmarks folders">
|
||||
<!ENTITY editBookmarkOverlay.expanderUp.tooltip "Hide">
|
||||
|
@ -76,8 +76,6 @@
|
||||
|
||||
<!ENTITY cmd.reloadLivebookmark.label "Reload Live Bookmark">
|
||||
<!ENTITY cmd.reloadLivebookmark.accesskey "R">
|
||||
<!ENTITY cmd.reloadMicrosummary.label "Reload Live Title">
|
||||
<!ENTITY cmd.reloadMicrosummary.accesskey "R">
|
||||
|
||||
<!ENTITY cmd.moveBookmarks.label "Move…">
|
||||
<!ENTITY cmd.moveBookmarks.accesskey "M">
|
||||
|
@ -1,2 +0,0 @@
|
||||
addMicsumGenConfirmTitle=Add Microsummary Generator
|
||||
addMicsumGenConfirmText=Add the following microsummary generator?\n\nSource: %S
|
@ -67,7 +67,6 @@
|
||||
locale/browser/preferences/sync.dtd (%chrome/browser/preferences/sync.dtd)
|
||||
#endif
|
||||
locale/browser/preferences/tabs.dtd (%chrome/browser/preferences/tabs.dtd)
|
||||
locale/browser/sidebar/sidebar.properties (%chrome/browser/sidebar/sidebar.properties)
|
||||
#ifdef MOZ_SERVICES_SYNC
|
||||
locale/browser/syncBrand.dtd (%chrome/browser/syncBrand.dtd)
|
||||
locale/browser/syncSetup.dtd (%chrome/browser/syncSetup.dtd)
|
||||
|
@ -405,7 +405,6 @@ menuitem:not([type]):not(.menuitem-tooltip):not(.menuitem-iconic-tooltip) {
|
||||
|
||||
#menu_reload,
|
||||
#placesContext_reload,
|
||||
#placesContext_reloadMicrosummary,
|
||||
#context-reload,
|
||||
#context-reloadframe {
|
||||
list-style-image: url("moz-icon://stock/gtk-refresh?size=menu");
|
||||
|
@ -77,36 +77,6 @@
|
||||
margin-bottom: 2px;
|
||||
}
|
||||
|
||||
/**** name picker ****/
|
||||
|
||||
/* Make the microsummary picker look like a regular textbox instead of
|
||||
* an editable menulist when no microsummaries are available.
|
||||
*/
|
||||
#editBMPanel_namePicker[droppable="false"] {
|
||||
/* These rules come from the textbox element in textbox.css. */
|
||||
-moz-appearance: textfield; /* Normal editable menulists set this to "none". */
|
||||
cursor: text;
|
||||
border: 2px solid;
|
||||
-moz-border-top-colors: ThreeDShadow ThreeDDarkShadow;
|
||||
-moz-border-right-colors: ThreeDHighlight ThreeDLightShadow;
|
||||
-moz-border-bottom-colors: ThreeDHighlight ThreeDLightShadow;
|
||||
-moz-border-left-colors: ThreeDShadow ThreeDDarkShadow;
|
||||
padding: 2px 2px 3px;
|
||||
-moz-padding-start: 4px;
|
||||
background-color: -moz-Field;
|
||||
color: -moz-FieldText;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-editable-box {
|
||||
-moz-appearance: none; /* Normal editable menulists set this to "menulist-textfield". */
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-dropmarker,
|
||||
#editBMPanel_namePicker[droppable="false"] > menupopup {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* Hide the value column of the tag autocomplete popup
|
||||
* leaving only the comment column visible. This is
|
||||
* so that only the tag being edited is shown in the
|
||||
|
@ -198,7 +198,6 @@ menuitem[command="placesCmd_show:info"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-properties?size=menu");
|
||||
}
|
||||
|
||||
#placesContext_reload,
|
||||
#placesContext_reloadMicrosummary {
|
||||
#placesContext_reload {
|
||||
list-style-image: url("moz-icon://stock/gtk-refresh?size=menu");
|
||||
}
|
||||
|
@ -1367,10 +1367,7 @@ richlistitem[type~="action"][actiontype="switchtab"] > .ac-url-box > .ac-action-
|
||||
list-style-image: url("chrome://browser/skin/hud-style-expander-closed.png");
|
||||
}
|
||||
|
||||
/**** name picker ****/
|
||||
|
||||
#editBMPanel_tagsField,
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-editable-box {
|
||||
#editBMPanel_tagsField {
|
||||
-moz-appearance: none !important;
|
||||
-moz-padding-start: 3px !important;
|
||||
margin: 2px !important;
|
||||
@ -1383,25 +1380,16 @@ richlistitem[type~="action"][actiontype="switchtab"] > .ac-url-box > .ac-action-
|
||||
min-height: 20px;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-editable-box > html|*.menulist-editable-input {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
#editBMPanel_tagsField > .autocomplete-textbox-container > .textbox-input-box > html|*.textbox-input:-moz-placeholder {
|
||||
color: #bbb;
|
||||
}
|
||||
|
||||
#editBMPanel_tagsField[focused="true"],
|
||||
#editBMPanel_namePicker[droppable="false"][focused="true"] > .menulist-editable-box {
|
||||
#editBMPanel_tagsField[focused="true"] {
|
||||
@hudButtonFocused@
|
||||
background-color: #eee !important;
|
||||
color: #000 !important;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"][disabled="true"] > .menulist-editable-box {
|
||||
color: #fff !important;
|
||||
}
|
||||
|
||||
.editBMPanel_rowLabel {
|
||||
text-align: end;
|
||||
}
|
||||
|
@ -92,70 +92,6 @@
|
||||
margin: 6px 4px 0 4px;
|
||||
}
|
||||
|
||||
/**** name picker ****/
|
||||
|
||||
/* Make the microsummary picker look like a regular textbox instead of
|
||||
* an editable menulist when no microsummaries are available.
|
||||
*/
|
||||
#editBMPanel_namePicker[droppable="false"] {
|
||||
-moz-appearance: none;
|
||||
margin: 0px;
|
||||
border: none;
|
||||
padding: 0px;
|
||||
height: auto !important;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-dropmarker {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-editable-box {
|
||||
/* These rules are duplicates of the rules for the textbox element
|
||||
* in textbox.css and should track changes in that file.
|
||||
*/
|
||||
-moz-appearance: textfield;
|
||||
cursor: text;
|
||||
margin: 4px 4px;
|
||||
border: 3px solid;
|
||||
-moz-border-top-colors: transparent #888888 #000000;
|
||||
-moz-border-right-colors: transparent #FFFFFF #000000;
|
||||
-moz-border-bottom-colors: transparent #FFFFFF #000000;
|
||||
-moz-border-left-colors: transparent #888888 #000000;
|
||||
border-top-right-radius: 2px;
|
||||
border-bottom-left-radius: 2px;
|
||||
padding: 0;
|
||||
background-color: -moz-Field;
|
||||
color: -moz-FieldText;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"][disabled="true"] > .menulist-editable-box {
|
||||
cursor: default;
|
||||
-moz-border-top-colors: transparent ThreeDShadow -moz-Dialog;
|
||||
-moz-border-right-colors: transparent ThreeDShadow -moz-Dialog;
|
||||
-moz-border-bottom-colors: transparent ThreeDShadow -moz-Dialog;
|
||||
-moz-border-left-colors: transparent ThreeDShadow -moz-Dialog;
|
||||
color: GrayText;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-editable-box > html|*.textbox-input {
|
||||
margin: 0px !important;
|
||||
border: none !important;
|
||||
padding: 0px !important;
|
||||
background-color: inherit;
|
||||
color: inherit;
|
||||
font: inherit;
|
||||
}
|
||||
|
||||
/* Hide the drop marker and the popup. */
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-dropmarker {
|
||||
display: none;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > menupopup {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* Hide the value column of the tag autocomplete popup
|
||||
* leaving only the comment column visible. This is
|
||||
* so that only the tag being edited is shown in the
|
||||
|
@ -82,35 +82,6 @@
|
||||
margin-bottom: 2px;
|
||||
}
|
||||
|
||||
/**** name picker ****/
|
||||
|
||||
/* Make the microsummary picker look like a regular textbox instead of
|
||||
* an editable menulist when no microsummaries are available.
|
||||
*/
|
||||
#editBMPanel_namePicker[droppable="false"] {
|
||||
/* These rules come from the textbox element in textbox.css. */
|
||||
-moz-appearance: textfield; /* Normal editable menulists set this to "menulist". */
|
||||
cursor: text;
|
||||
border: 2px solid;
|
||||
-moz-border-top-colors: ThreeDShadow ThreeDDarkShadow;
|
||||
-moz-border-right-colors: ThreeDHighlight ThreeDLightShadow;
|
||||
-moz-border-bottom-colors: ThreeDHighlight ThreeDLightShadow;
|
||||
-moz-border-left-colors: ThreeDShadow ThreeDDarkShadow;
|
||||
padding: 2px 2px 3px;
|
||||
-moz-padding-start: 4px;
|
||||
background-color: -moz-Field;
|
||||
color: -moz-FieldText;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-editable-box {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
#editBMPanel_namePicker[droppable="false"] > .menulist-dropmarker,
|
||||
#editBMPanel_namePicker[droppable="false"] > menupopup {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* Hide the value column of the tag autocomplete popup
|
||||
* leaving only the comment column visible. This is
|
||||
* so that only the tag being edited is shown in the
|
||||
|
@ -145,7 +145,6 @@ MOZ_TOOLKIT_SEARCH = @MOZ_TOOLKIT_SEARCH@
|
||||
MOZ_PLACES = @MOZ_PLACES@
|
||||
MOZ_STORAGE = @MOZ_STORAGE@
|
||||
MOZ_SAFE_BROWSING = @MOZ_SAFE_BROWSING@
|
||||
MOZ_FASTSTART = @MOZ_FASTSTART@
|
||||
MOZ_URL_CLASSIFIER = @MOZ_URL_CLASSIFIER@
|
||||
MOZ_ZIPWRITER = @MOZ_ZIPWRITER@
|
||||
MOZ_MORK = @MOZ_MORK@
|
||||
|
@ -91,17 +91,20 @@ VPATH += $(LIBXUL_SDK)/lib
|
||||
endif
|
||||
|
||||
# EXPAND_LIBNAME - $(call EXPAND_LIBNAME,foo)
|
||||
# expands to foo.lib on platforms with import libs and -lfoo otherwise
|
||||
# expands to $(LIB_PREFIX)foo.$(LIB_SUFFIX) or -lfoo, depending on linker
|
||||
# arguments syntax. Should only be used for system libraries
|
||||
|
||||
# EXPAND_LIBNAME_PATH - $(call EXPAND_LIBNAME_PATH,foo,dir)
|
||||
# expands to dir/foo.lib on platforms with import libs and
|
||||
# -Ldir -lfoo otherwise
|
||||
# expands to dir/$(LIB_PREFIX)foo.$(LIB_SUFFIX)
|
||||
|
||||
# EXPAND_MOZLIBNAME - $(call EXPAND_MOZLIBNAME,foo)
|
||||
# expands to $(DIST)/lib/foo.lib on platforms with import libs and
|
||||
# -lfoo otherwise
|
||||
# expands to $(DIST)/lib/$(LIB_PREFIX)foo.$(LIB_SUFFIX)
|
||||
|
||||
ifdef GNU_CC
|
||||
EXPAND_LIBNAME = $(addprefix -l,$(1))
|
||||
else
|
||||
EXPAND_LIBNAME = $(foreach lib,$(1),$(LIB_PREFIX)$(lib).$(LIB_SUFFIX))
|
||||
endif
|
||||
EXPAND_LIBNAME_PATH = $(foreach lib,$(1),$(2)/$(LIB_PREFIX)$(lib).$(LIB_SUFFIX))
|
||||
EXPAND_MOZLIBNAME = $(foreach lib,$(1),$(DIST)/lib/$(LIB_PREFIX)$(lib).$(LIB_SUFFIX))
|
||||
|
||||
|
25
configure.in
25
configure.in
@ -2188,9 +2188,9 @@ ia64*-hpux*)
|
||||
esac
|
||||
# If we're building with --enable-profiling, we need a frame pointer.
|
||||
if test -z "$MOZ_PROFILING"; then
|
||||
MOZ_OPTIMIZE_FLAGS="-Os -freorder-blocks -fomit-frame-pointer $MOZ_OPTIMIZE_SIZE_TWEAK"
|
||||
MOZ_OPTIMIZE_FLAGS="-O3 -fomit-frame-pointer"
|
||||
else
|
||||
MOZ_OPTIMIZE_FLAGS="-Os -freorder-blocks -fno-omit-frame-pointer $MOZ_OPTIMIZE_SIZE_TWEAK"
|
||||
MOZ_OPTIMIZE_FLAGS="-O3 -fno-omit-frame-pointer"
|
||||
fi
|
||||
MOZ_DEBUG_FLAGS="-g"
|
||||
fi
|
||||
@ -3178,7 +3178,7 @@ dnl Checks for header files.
|
||||
dnl ========================================================
|
||||
AC_HEADER_DIRENT
|
||||
case "$target_os" in
|
||||
freebsd*)
|
||||
freebsd*|openbsd*)
|
||||
# for stuff like -lXshm
|
||||
CPPFLAGS="${CPPFLAGS} ${X_CFLAGS}"
|
||||
;;
|
||||
@ -3344,11 +3344,6 @@ else
|
||||
dnl ========================================================
|
||||
AC_CHECK_LIB(Xext, XShmCreateImage, _HAVE_XSHM_XEXT=1,,
|
||||
$XLIBS $XEXT_LIBS)
|
||||
MOZ_CHECK_HEADER(X11/extensions/XShm.h)
|
||||
if test "$ac_cv_header_X11_extensions_XShm_h" = "yes" &&
|
||||
test -n "$_HAVE_XSHM_XEXT"; then
|
||||
AC_DEFINE(HAVE_XSHM)
|
||||
fi
|
||||
|
||||
dnl ========================================================
|
||||
dnl = Check for Xss
|
||||
@ -4802,7 +4797,6 @@ MOZ_PSM=1
|
||||
MOZ_RDF=1
|
||||
MOZ_REFLOW_PERF=
|
||||
MOZ_SAFE_BROWSING=
|
||||
MOZ_FASTSTART=
|
||||
MOZ_HELP_VIEWER=
|
||||
MOZ_SPELLCHECK=1
|
||||
MOZ_SPLASHSCREEN=
|
||||
@ -6771,18 +6765,6 @@ if test -n "$MOZ_SAFE_BROWSING"; then
|
||||
fi
|
||||
AC_SUBST(MOZ_SAFE_BROWSING)
|
||||
|
||||
dnl ========================================================
|
||||
dnl = Enable faststart component
|
||||
dnl ========================================================
|
||||
MOZ_ARG_ENABLE_BOOL(faststart,
|
||||
[ --enable-faststart Enable the faststart component],
|
||||
MOZ_FASTSTART=1,
|
||||
MOZ_FASTSTART= )
|
||||
if test -n "$MOZ_FASTSTART"; then
|
||||
AC_DEFINE(MOZ_FASTSTART)
|
||||
fi
|
||||
AC_SUBST(MOZ_FASTSTART)
|
||||
|
||||
dnl ========================================================
|
||||
dnl = Enable url-classifier
|
||||
dnl ========================================================
|
||||
@ -9041,6 +9023,7 @@ if test "$MOZ_X11"; then
|
||||
#include <stdlib.h>
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/Intrinsic.h>
|
||||
#include <X11/extensions/XShm.h>
|
||||
],
|
||||
[
|
||||
Display *dpy = 0;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user