mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Merge from cvs-trunk-mirror to mozilla-central.
--HG-- rename : js/src/js.c => js/src/js.cpp rename : js/src/jsapi.c => js/src/jsapi.cpp rename : js/src/jsarray.c => js/src/jsarray.cpp rename : js/src/jsbool.c => js/src/jsbool.cpp rename : js/src/jscntxt.c => js/src/jscntxt.cpp rename : js/src/jsdate.c => js/src/jsdate.cpp rename : js/src/jsemit.c => js/src/jsemit.cpp rename : js/src/jsfun.c => js/src/jsfun.cpp rename : js/src/jsgc.c => js/src/jsgc.cpp rename : js/src/jsinterp.c => js/src/jsinterp.cpp rename : js/src/jsiter.c => js/src/jsiter.cpp rename : js/src/jslock.c => js/src/jslock.cpp rename : js/src/jsnum.c => js/src/jsnum.cpp rename : js/src/jsobj.c => js/src/jsobj.cpp rename : js/src/jsparse.c => js/src/jsparse.cpp rename : js/src/jsregexp.c => js/src/jsregexp.cpp rename : js/src/jsstr.c => js/src/jsstr.cpp rename : js/src/jsxml.c => js/src/jsxml.cpp
This commit is contained in:
commit
a3cdb83c9b
@ -118,6 +118,11 @@ class nsAccessNode: public nsIAccessNode, public nsPIAccessNode
|
||||
static nsIAccessibilityService* GetAccService();
|
||||
already_AddRefed<nsIDOMNode> GetCurrentFocus();
|
||||
|
||||
/**
|
||||
* Returns true when the accessible is defunct.
|
||||
*/
|
||||
virtual PRBool IsDefunct() { return !mDOMNode; }
|
||||
|
||||
protected:
|
||||
nsresult MakeAccessNode(nsIDOMNode *aNode, nsIAccessNode **aAccessNode);
|
||||
already_AddRefed<nsIPresShell> GetPresShell();
|
||||
|
@ -1351,8 +1351,13 @@ NS_IMETHODIMP nsAccessibilityService::GetAccessible(nsIDOMNode *aNode,
|
||||
if (content->IsNodeOfType(nsINode::eTEXT)) {
|
||||
// --- Create HTML for visible text frames ---
|
||||
if (frame->IsEmpty()) {
|
||||
*aIsHidden = PR_TRUE;
|
||||
return NS_OK;
|
||||
nsAutoString renderedWhitespace;
|
||||
frame->GetRenderedText(&renderedWhitespace, nsnull, nsnull, 0, 1);
|
||||
if (renderedWhitespace.IsEmpty()) {
|
||||
// Really empty -- nothing is rendered
|
||||
*aIsHidden = PR_TRUE;
|
||||
return NS_OK;
|
||||
}
|
||||
}
|
||||
frame->GetAccessible(getter_AddRefs(newAcc));
|
||||
return InitAccessible(newAcc, aAccessible, nsnull);
|
||||
|
@ -937,12 +937,17 @@ PRBool nsAccessible::IsVisible(PRBool *aIsOffscreen)
|
||||
&rectVisibility);
|
||||
|
||||
if (rectVisibility == nsRectVisibility_kZeroAreaRect) {
|
||||
if (frame->GetNextContinuation()) {
|
||||
nsIAtom *frameType = frame->GetType();
|
||||
if (frameType == nsAccessibilityAtoms::textFrame) {
|
||||
// Zero area rects can occur in the first frame of a multi-frame text flow,
|
||||
// in which case the next frame exists because the text flow is visible
|
||||
rectVisibility = nsRectVisibility_kVisible;
|
||||
// in which case the rendered text is not empty and the frame should not be marked invisible
|
||||
nsAutoString renderedText;
|
||||
frame->GetRenderedText (&renderedText, nsnull, nsnull, 0, 1);
|
||||
if (!renderedText.IsEmpty()) {
|
||||
rectVisibility = nsRectVisibility_kVisible;
|
||||
}
|
||||
}
|
||||
else if (IsCorrectFrameType(frame, nsAccessibilityAtoms::inlineFrame)) {
|
||||
else if (frameType == nsAccessibilityAtoms::inlineFrame) {
|
||||
// Yuck. Unfortunately inline frames can contain larger frames inside of them,
|
||||
// so we can't really believe this is a zero area rect without checking more deeply.
|
||||
// GetBounds() will do that for us.
|
||||
|
@ -167,6 +167,7 @@ NS_IMETHODIMP nsCaretAccessible::NotifySelectionChanged(nsIDOMDocument *aDoc, ns
|
||||
mLastUsedSelection = do_GetWeakReference(aSel);
|
||||
|
||||
nsCOMPtr<nsIDocument> doc = do_QueryInterface(aDoc);
|
||||
NS_ENSURE_TRUE(doc, NS_OK);
|
||||
nsIPresShell *presShell = doc->GetPrimaryShell();
|
||||
NS_ENSURE_TRUE(presShell, NS_OK);
|
||||
|
||||
|
@ -534,17 +534,25 @@ NS_IMETHODIMP nsDocAccessible::Shutdown()
|
||||
|
||||
mWeakShell = nsnull; // Avoid reentrancy
|
||||
|
||||
if (mFireEventTimer) {
|
||||
mFireEventTimer->Cancel();
|
||||
mFireEventTimer = nsnull;
|
||||
}
|
||||
mEventsToFire.Clear();
|
||||
|
||||
ClearCache(mAccessNodeCache);
|
||||
|
||||
mDocument = nsnull;
|
||||
|
||||
return nsHyperTextAccessibleWrap::Shutdown();
|
||||
nsHyperTextAccessibleWrap::Shutdown();
|
||||
|
||||
if (mFireEventTimer) {
|
||||
// Doc being shut down before events fired,
|
||||
mFireEventTimer->Cancel();
|
||||
mFireEventTimer = nsnull;
|
||||
if (mEventsToFire.Count() > 0 ) {
|
||||
mEventsToFire.Clear();
|
||||
// Make sure we release the kung fu death grip which is always
|
||||
// there when there are still events left to be fired
|
||||
NS_RELEASE_THIS();
|
||||
}
|
||||
}
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
void nsDocAccessible::ShutdownChildDocuments(nsIDocShellTreeItem *aStart)
|
||||
@ -1471,6 +1479,7 @@ nsDocAccessible::FireDelayedAccessibleEvent(nsIAccessibleEvent *aEvent,
|
||||
if (!isTimerStarted) {
|
||||
// This is be the first delayed event in queue, start timer
|
||||
// so that event gets fired via FlushEventsCallback
|
||||
NS_ADDREF_THIS(); // Kung fu death grip to prevent crash in callback
|
||||
mFireEventTimer->InitWithFuncCallback(FlushEventsCallback,
|
||||
static_cast<nsPIAccessibleDocument*>(this),
|
||||
0, nsITimer::TYPE_ONE_SHOT);
|
||||
@ -1595,6 +1604,7 @@ NS_IMETHODIMP nsDocAccessible::FlushPendingEvents()
|
||||
}
|
||||
}
|
||||
mEventsToFire.Clear(); // Clear out array
|
||||
NS_RELEASE_THIS(); // Release kung fu death grip
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
@ -1602,7 +1612,11 @@ void nsDocAccessible::FlushEventsCallback(nsITimer *aTimer, void *aClosure)
|
||||
{
|
||||
nsPIAccessibleDocument *accessibleDoc = static_cast<nsPIAccessibleDocument*>(aClosure);
|
||||
NS_ASSERTION(accessibleDoc, "How did we get here without an accessible document?");
|
||||
accessibleDoc->FlushPendingEvents();
|
||||
if (accessibleDoc) {
|
||||
// A lot of crashes were happening here, so now we're reffing the doc
|
||||
// now until the events are flushed
|
||||
accessibleDoc->FlushPendingEvents();
|
||||
}
|
||||
}
|
||||
|
||||
void nsDocAccessible::RefreshNodes(nsIDOMNode *aStartNode)
|
||||
|
@ -507,6 +507,8 @@ NS_IMETHODIMP
|
||||
nsHTMLTableAccessible::CellRefAt(PRInt32 aRow, PRInt32 aColumn,
|
||||
nsIAccessible **aTableCellAccessible)
|
||||
{
|
||||
NS_ENSURE_TRUE(IsValidRow(aRow) && IsValidColumn(aColumn), NS_ERROR_INVALID_ARG);
|
||||
|
||||
nsresult rv = NS_OK;
|
||||
|
||||
nsCOMPtr<nsIDOMElement> cellElement;
|
||||
@ -527,6 +529,8 @@ nsHTMLTableAccessible::GetIndexAt(PRInt32 aRow, PRInt32 aColumn,
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aIndex);
|
||||
|
||||
NS_ENSURE_TRUE(IsValidRow(aRow) && IsValidColumn(aColumn), NS_ERROR_INVALID_ARG);
|
||||
|
||||
nsresult rv = NS_OK;
|
||||
nsCOMPtr<nsIDOMElement> domElement;
|
||||
rv = GetCellAt(aRow, aColumn, *getter_AddRefs(domElement));
|
||||
@ -550,8 +554,11 @@ nsHTMLTableAccessible::GetColumnAtIndex(PRInt32 aIndex, PRInt32 *aColumn)
|
||||
|
||||
nsCOMPtr<nsIAccessible> child;
|
||||
GetChildAt(aIndex, getter_AddRefs(child));
|
||||
NS_ENSURE_TRUE(child, NS_ERROR_FAILURE);
|
||||
nsCOMPtr<nsPIAccessNode> childNode(do_QueryInterface(child));
|
||||
NS_ASSERTION(childNode, "childNode not valid in GetColumnAtIndex!");
|
||||
nsIFrame* frame = childNode->GetFrame();
|
||||
NS_ENSURE_TRUE(frame, NS_ERROR_FAILURE);
|
||||
nsCOMPtr<nsITableCellLayout> cellLayout(do_QueryInterface(frame));
|
||||
NS_ENSURE_TRUE(cellLayout, NS_ERROR_FAILURE);
|
||||
return cellLayout->GetColIndex(*aColumn);
|
||||
@ -564,8 +571,11 @@ nsHTMLTableAccessible::GetRowAtIndex(PRInt32 aIndex, PRInt32 *aRow)
|
||||
|
||||
nsCOMPtr<nsIAccessible> child;
|
||||
GetChildAt(aIndex, getter_AddRefs(child));
|
||||
NS_ENSURE_TRUE(child, NS_ERROR_FAILURE);
|
||||
nsCOMPtr<nsPIAccessNode> childNode(do_QueryInterface(child));
|
||||
NS_ASSERTION(childNode, "childNode not valid in GetRowAtIndex!");
|
||||
nsIFrame* frame = childNode->GetFrame();
|
||||
NS_ENSURE_TRUE(frame, NS_ERROR_FAILURE);
|
||||
nsCOMPtr<nsITableCellLayout> cellLayout(do_QueryInterface(frame));
|
||||
NS_ENSURE_TRUE(cellLayout, NS_ERROR_FAILURE);
|
||||
return cellLayout->GetRowIndex(*aRow);
|
||||
@ -575,6 +585,8 @@ NS_IMETHODIMP
|
||||
nsHTMLTableAccessible::GetColumnExtentAt(PRInt32 aRow, PRInt32 aColumn,
|
||||
PRInt32 *_retval)
|
||||
{
|
||||
NS_ENSURE_TRUE(IsValidRow(aRow) && IsValidColumn(aColumn), NS_ERROR_INVALID_ARG);
|
||||
|
||||
nsresult rv = NS_OK;
|
||||
|
||||
nsCOMPtr<nsIDOMElement> domElement;
|
||||
@ -591,6 +603,8 @@ NS_IMETHODIMP
|
||||
nsHTMLTableAccessible::GetRowExtentAt(PRInt32 aRow, PRInt32 aColumn,
|
||||
PRInt32 *_retval)
|
||||
{
|
||||
NS_ENSURE_TRUE(IsValidRow(aRow) && IsValidColumn(aColumn), NS_ERROR_INVALID_ARG);
|
||||
|
||||
nsresult rv = NS_OK;
|
||||
|
||||
nsCOMPtr<nsIDOMElement> domElement;
|
||||
@ -620,6 +634,8 @@ nsHTMLTableAccessible::IsColumnSelected(PRInt32 aColumn, PRBool *_retval)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(_retval);
|
||||
|
||||
NS_ENSURE_TRUE(IsValidColumn(aColumn), NS_ERROR_INVALID_ARG);
|
||||
|
||||
nsresult rv = NS_OK;
|
||||
|
||||
PRInt32 rows;
|
||||
@ -642,6 +658,8 @@ nsHTMLTableAccessible::IsRowSelected(PRInt32 aRow, PRBool *_retval)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(_retval);
|
||||
|
||||
NS_ENSURE_TRUE(IsValidRow(aRow), NS_ERROR_INVALID_ARG);
|
||||
|
||||
nsresult rv = NS_OK;
|
||||
|
||||
PRInt32 columns;
|
||||
@ -663,6 +681,8 @@ NS_IMETHODIMP
|
||||
nsHTMLTableAccessible::IsCellSelected(PRInt32 aRow, PRInt32 aColumn,
|
||||
PRBool *_retval)
|
||||
{
|
||||
NS_ENSURE_TRUE(IsValidRow(aRow) && IsValidColumn(aColumn), NS_ERROR_INVALID_ARG);
|
||||
|
||||
nsITableLayout *tableLayout;
|
||||
nsresult rv = GetTableLayout(&tableLayout);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
@ -678,6 +698,22 @@ nsHTMLTableAccessible::IsCellSelected(PRInt32 aRow, PRInt32 aColumn,
|
||||
*_retval);
|
||||
}
|
||||
|
||||
PRBool
|
||||
nsHTMLTableAccessible::IsValidColumn(PRInt32 aColumn)
|
||||
{
|
||||
PRInt32 colCount = 0;
|
||||
nsresult rv = GetColumns(&colCount);
|
||||
return NS_SUCCEEDED(rv) && (aColumn >= 0) && (aColumn < colCount);
|
||||
}
|
||||
|
||||
PRBool
|
||||
nsHTMLTableAccessible::IsValidRow(PRInt32 aRow)
|
||||
{
|
||||
PRInt32 rowCount = 0;
|
||||
nsresult rv = GetRows(&rowCount);
|
||||
return NS_SUCCEEDED(rv) && (aRow >= 0) && (aRow < rowCount);
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsHTMLTableAccessible::SelectRow(PRInt32 aRow)
|
||||
{
|
||||
|
@ -73,6 +73,20 @@ public:
|
||||
NS_IMETHOD GetDescription(nsAString& aDescription);
|
||||
NS_IMETHOD GetAccessibleRelated(PRUint32 aRelationType, nsIAccessible **aRelated);
|
||||
|
||||
/**
|
||||
* Returns true if the column index is in the valid column range.
|
||||
*
|
||||
* @param aColumn The index to check for validity.
|
||||
*/
|
||||
PRBool IsValidColumn(PRInt32 aColumn);
|
||||
|
||||
/**
|
||||
* Returns true if the given index is in the valid row range.
|
||||
*
|
||||
* @param aRow The index to check for validity.
|
||||
*/
|
||||
PRBool IsValidRow(PRInt32 aRow);
|
||||
|
||||
protected:
|
||||
|
||||
/**
|
||||
|
@ -670,7 +670,9 @@ NS_IMETHODIMP nsXULTreeitemAccessible::Shutdown()
|
||||
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::GetName(nsAString& aName)
|
||||
{
|
||||
NS_ENSURE_TRUE(mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
mTreeView->GetCellText(mRow, mColumn, aName);
|
||||
|
||||
// If there is still no name try the cell value:
|
||||
@ -713,7 +715,11 @@ nsXULTreeitemAccessible::GetState(PRUint32 *aState, PRUint32 *aExtraState)
|
||||
if (aExtraState)
|
||||
*aExtraState = 0;
|
||||
|
||||
NS_ENSURE_TRUE(mColumn && mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (IsDefunct()) {
|
||||
if (aExtraState)
|
||||
*aExtraState = nsIAccessibleStates::EXT_STATE_DEFUNCT;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
*aState = nsIAccessibleStates::STATE_FOCUSABLE |
|
||||
nsIAccessibleStates::STATE_SELECTABLE;
|
||||
@ -767,9 +773,22 @@ nsXULTreeitemAccessible::GetState(PRUint32 *aState, PRUint32 *aExtraState)
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
PRBool
|
||||
nsXULTreeitemAccessible::IsDefunct()
|
||||
{
|
||||
if (!mTree || !mTreeView || !mColumn || mRow < 0)
|
||||
return PR_TRUE;
|
||||
|
||||
PRInt32 rowCount = 0;
|
||||
nsresult rv = mTreeView->GetRowCount(&rowCount);
|
||||
return NS_FAILED(rv) || mRow >= rowCount;
|
||||
}
|
||||
|
||||
PRBool nsXULTreeitemAccessible::IsExpandable()
|
||||
{
|
||||
NS_ENSURE_TRUE(mTree && mTreeView && mColumn, NS_ERROR_FAILURE);
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
PRBool isContainer;
|
||||
mTreeView->IsContainer(mRow, &isContainer);
|
||||
if (isContainer) {
|
||||
@ -790,16 +809,21 @@ PRBool nsXULTreeitemAccessible::IsExpandable()
|
||||
// "expand/collapse" action is avaible for treeitem which is container
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::GetNumActions(PRUint8 *aNumActions)
|
||||
{
|
||||
NS_ENSURE_TRUE(mTree && mTreeView && mColumn, NS_ERROR_FAILURE);
|
||||
*aNumActions = IsExpandable() ? 2 : 1;
|
||||
NS_ENSURE_ARG_POINTER(aNumActions);
|
||||
*aNumActions = 0;
|
||||
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
*aNumActions = IsExpandable() ? 2 : 1;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
// Return the name of our actions
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::GetActionName(PRUint8 aIndex, nsAString& aName)
|
||||
{
|
||||
NS_ENSURE_TRUE(mColumn && mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
if (aIndex == eAction_Click) {
|
||||
PRBool isCycler;
|
||||
@ -829,7 +853,9 @@ nsresult
|
||||
nsXULTreeitemAccessible::GetAttributesInternal(nsIPersistentProperties *aAttributes)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aAttributes);
|
||||
NS_ENSURE_TRUE(mDOMNode, NS_ERROR_FAILURE);
|
||||
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
nsresult rv = nsLeafAccessible::GetAttributesInternal(aAttributes);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
@ -892,8 +918,12 @@ nsXULTreeitemAccessible::GetAttributesInternal(nsIPersistentProperties *aAttribu
|
||||
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::GetParent(nsIAccessible **aParent)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aParent);
|
||||
*aParent = nsnull;
|
||||
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
if (mParent) {
|
||||
*aParent = mParent;
|
||||
NS_ADDREF(*aParent);
|
||||
@ -906,9 +936,11 @@ NS_IMETHODIMP nsXULTreeitemAccessible::GetParent(nsIAccessible **aParent)
|
||||
// otherwise return the next cell.
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::GetNextSibling(nsIAccessible **aNextSibling)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aNextSibling);
|
||||
*aNextSibling = nsnull;
|
||||
|
||||
NS_ENSURE_TRUE(mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
nsCOMPtr<nsIAccessibleTreeCache> treeCache(do_QueryInterface(mParent));
|
||||
NS_ENSURE_TRUE(treeCache, NS_ERROR_FAILURE);
|
||||
@ -953,9 +985,11 @@ NS_IMETHODIMP nsXULTreeitemAccessible::GetNextSibling(nsIAccessible **aNextSibli
|
||||
// otherwise return the previous cell.
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::GetPreviousSibling(nsIAccessible **aPreviousSibling)
|
||||
{
|
||||
NS_ENSURE_ARG_POINTER(aPreviousSibling);
|
||||
*aPreviousSibling = nsnull;
|
||||
|
||||
NS_ENSURE_TRUE(mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
nsCOMPtr<nsIAccessibleTreeCache> treeCache(do_QueryInterface(mParent));
|
||||
NS_ENSURE_TRUE(treeCache, NS_ERROR_FAILURE);
|
||||
@ -989,7 +1023,8 @@ NS_IMETHODIMP nsXULTreeitemAccessible::GetPreviousSibling(nsIAccessible **aPrevi
|
||||
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::DoAction(PRUint8 index)
|
||||
{
|
||||
NS_ENSURE_TRUE(mColumn && mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
if (index == eAction_Click) {
|
||||
nsresult rv = NS_OK;
|
||||
@ -1017,9 +1052,17 @@ NS_IMETHODIMP nsXULTreeitemAccessible::DoAction(PRUint8 index)
|
||||
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::GetBounds(PRInt32 *x, PRInt32 *y, PRInt32 *width, PRInt32 *height)
|
||||
{
|
||||
*x = *y = *width = *height = 0;
|
||||
NS_ENSURE_ARG_POINTER(x);
|
||||
*x = 0;
|
||||
NS_ENSURE_ARG_POINTER(y);
|
||||
*y = 0;
|
||||
NS_ENSURE_ARG_POINTER(width);
|
||||
*width = 0;
|
||||
NS_ENSURE_ARG_POINTER(height);
|
||||
*height = 0;
|
||||
|
||||
NS_ENSURE_TRUE(mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
// This Bounds are based on Tree's coord
|
||||
mTree->GetCoordsForCellItem(mRow, mColumn, EmptyCString(), x, y, width, height);
|
||||
@ -1068,7 +1111,8 @@ NS_IMETHODIMP nsXULTreeitemAccessible::GetBounds(PRInt32 *x, PRInt32 *y, PRInt32
|
||||
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::SetSelected(PRBool aSelect)
|
||||
{
|
||||
NS_ENSURE_TRUE(mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
nsCOMPtr<nsITreeSelection> selection;
|
||||
mTreeView->GetSelection(getter_AddRefs(selection));
|
||||
@ -1083,8 +1127,9 @@ NS_IMETHODIMP nsXULTreeitemAccessible::SetSelected(PRBool aSelect)
|
||||
}
|
||||
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::TakeFocus()
|
||||
{
|
||||
NS_ENSURE_TRUE(mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
{
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
nsCOMPtr<nsITreeSelection> selection;
|
||||
mTreeView->GetSelection(getter_AddRefs(selection));
|
||||
@ -1097,11 +1142,13 @@ NS_IMETHODIMP nsXULTreeitemAccessible::TakeFocus()
|
||||
|
||||
NS_IMETHODIMP nsXULTreeitemAccessible::GetAccessibleRelated(PRUint32 aRelationType, nsIAccessible **aRelated)
|
||||
{
|
||||
if (IsDefunct())
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
//currentlly only for ATK. and in the future, we'll sync MSAA and ATK same.
|
||||
//that's why ATK specific code shows here
|
||||
*aRelated = nsnull;
|
||||
#ifdef MOZ_ACCESSIBILITY_ATK
|
||||
NS_ENSURE_TRUE(mColumn && mTree && mTreeView, NS_ERROR_FAILURE);
|
||||
if (aRelationType == nsIAccessibleRelation::RELATION_NODE_CHILD_OF) {
|
||||
PRInt32 columnIndex;
|
||||
if (NS_SUCCEEDED(mColumn->GetIndex(&columnIndex)) && columnIndex == 0) {
|
||||
|
@ -126,6 +126,9 @@ public:
|
||||
/* ------ nsIAccessNode ----- */
|
||||
NS_IMETHOD GetUniqueID(void **aUniqueID);
|
||||
|
||||
// nsAccessNode
|
||||
virtual PRBool IsDefunct();
|
||||
|
||||
protected:
|
||||
PRBool IsExpandable();
|
||||
nsCOMPtr<nsITreeBoxObject> mTree;
|
||||
|
@ -151,6 +151,13 @@ endif
|
||||
NSDISTMODE = copy
|
||||
|
||||
include $(topsrcdir)/config/config.mk
|
||||
|
||||
ifdef _MSC_VER
|
||||
# Always enter a Windows program through wmain, whether or not we're
|
||||
# a console application.
|
||||
WIN32_EXE_LDFLAGS += -ENTRY:wmainCRTStartup
|
||||
endif
|
||||
|
||||
ifndef BUILD_STATIC_LIBS
|
||||
|
||||
ifdef NS_TRACE_MALLOC
|
||||
|
@ -41,7 +41,7 @@ Vendor=Mozilla
|
||||
Name=Firefox
|
||||
Version=@APP_VERSION@
|
||||
BuildID=@GRE_BUILDID@
|
||||
Copyright=Copyright (c) 1998 - 2007 mozilla.org
|
||||
Copyright=Copyright (c) 1998 - 2008 mozilla.org
|
||||
ID={ec8030f7-c20a-464f-9b0e-13a3a9e97384}
|
||||
|
||||
[Gecko]
|
||||
|
@ -74,7 +74,7 @@
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>firefox-bin</string>
|
||||
<key>CFBundleGetInfoString</key>
|
||||
<string>%APP_NAME% %APP_VERSION%, © 1998-2007 Contributors</string>
|
||||
<string>%APP_NAME% %APP_VERSION%, © 1998-2008 Contributors</string>
|
||||
<key>CFBundleIconFile</key>
|
||||
<string>firefox</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
|
@ -1,2 +1,2 @@
|
||||
CFBundleName = "%APP_NAME%";
|
||||
NSHumanReadableCopyright = "Copyright © 1998-2007 Contributors";
|
||||
NSHumanReadableCopyright = "Copyright © 1998-2008 Contributors";
|
||||
|
@ -53,6 +53,11 @@
|
||||
#include "nsILocalFile.h"
|
||||
#include "nsStringGlue.h"
|
||||
|
||||
#ifdef XP_WIN
|
||||
// we want a wmain entry point
|
||||
#include "nsWindowsWMain.cpp"
|
||||
#endif
|
||||
|
||||
static void Output(const char *fmt, ... )
|
||||
{
|
||||
va_list ap;
|
||||
@ -156,13 +161,3 @@ int main(int argc, char* argv[])
|
||||
PR_smprintf_free(appEnv);
|
||||
return result;
|
||||
}
|
||||
|
||||
#if defined( XP_WIN ) && defined( WIN32 ) && !defined(__GNUC__)
|
||||
// We need WinMain in order to not be a console app. This function is
|
||||
// unused if we are a console application.
|
||||
int WINAPI WinMain( HINSTANCE, HINSTANCE, LPSTR args, int )
|
||||
{
|
||||
// Do the real work.
|
||||
return main( __argc, __argv );
|
||||
}
|
||||
#endif
|
||||
|
@ -190,7 +190,7 @@ pref("browser.chrome.favicons", true);
|
||||
pref("browser.formfill.enable", true);
|
||||
pref("browser.warnOnQuit", true);
|
||||
|
||||
#ifdef XP_UNIX
|
||||
#ifdef UNIX_BUT_NOT_MAC
|
||||
pref("browser.urlbar.clickSelectsAll", false);
|
||||
#else
|
||||
pref("browser.urlbar.clickSelectsAll", true);
|
||||
@ -203,8 +203,6 @@ pref("browser.urlbar.doubleClickSelectsAll", false);
|
||||
pref("browser.urlbar.autoFill", false);
|
||||
pref("browser.urlbar.matchOnlyTyped", false);
|
||||
|
||||
// if false, will use one-line-per-result for urlbar autocomplete
|
||||
pref("browser.urlbar.richResults", true);
|
||||
// the maximum number of results to show in autocomplete when doing richResults
|
||||
pref("browser.urlbar.maxRichResults", 25);
|
||||
|
||||
@ -219,7 +217,6 @@ pref("browser.download.manager.closeWhenDone", false);
|
||||
pref("browser.download.manager.openDelay", 0);
|
||||
pref("browser.download.manager.focusWhenStarting", false);
|
||||
pref("browser.download.manager.flashCount", 2);
|
||||
pref("browser.download.manager.displayedHistoryDays", 7);
|
||||
pref("browser.download.manager.addToRecentDocs", true);
|
||||
|
||||
// search engines URL
|
||||
@ -273,7 +270,12 @@ pref("browser.link.open_newwindow", 3);
|
||||
// 2: don't divert window.open with features
|
||||
pref("browser.link.open_newwindow.restriction", 2);
|
||||
|
||||
// Tab browser preferences.
|
||||
// Tabbed browser
|
||||
pref("browser.tabs.autoHide", true);
|
||||
pref("browser.tabs.forceHide", false);
|
||||
pref("browser.tabs.warnOnClose", true);
|
||||
pref("browser.tabs.warnOnOpen", true);
|
||||
pref("browser.tabs.maxOpenBeforeWarn", 15);
|
||||
pref("browser.tabs.loadInBackground", true);
|
||||
pref("browser.tabs.loadFolderAndReplace", true);
|
||||
pref("browser.tabs.opentabfor.middleclick", true);
|
||||
@ -348,8 +350,7 @@ pref("privacy.sanitize.promptOnSanitize", true);
|
||||
|
||||
pref("network.proxy.share_proxy_settings", false); // use the same proxy settings for all protocols
|
||||
|
||||
pref("network.cookie.cookieBehavior", 0); // cookies enabled
|
||||
pref("network.cookie.enableForCurrentSessionOnly", false);
|
||||
pref("network.cookie.cookieBehavior", 1); // 0-Accept, 1-dontAcceptForeign, 2-dontUse
|
||||
|
||||
// l12n and i18n
|
||||
pref("intl.accept_languages", "chrome://global/locale/intl.properties");
|
||||
@ -454,7 +455,11 @@ pref("browser.preferences.instantApply", false);
|
||||
#else
|
||||
pref("browser.preferences.instantApply", true);
|
||||
#endif
|
||||
#ifdef XP_MACOSX
|
||||
pref("browser.preferences.animateFadeIn", true);
|
||||
#else
|
||||
pref("browser.preferences.animateFadeIn", false);
|
||||
#endif
|
||||
|
||||
pref("browser.download.show_plugins_in_list", true);
|
||||
pref("browser.download.hide_plugins_without_extensions", true);
|
||||
@ -598,3 +603,7 @@ pref("browser.places.migratePostDataAnnotations", true);
|
||||
// 1 - pre-populate site URL, but don't fetch certificate
|
||||
// 2 - pre-populate site URL and pre-fetch certificate
|
||||
pref("browser.ssl_override_behavior", 1);
|
||||
|
||||
// replace newlines with spaces when pasting into <input type="text"> fields
|
||||
pref("editor.singleLine.pasteNewlines", 2);
|
||||
|
||||
|
@ -109,10 +109,12 @@
|
||||
<menuitem id="context-back"
|
||||
label="&backCmd.label;"
|
||||
accesskey="&backCmd.accesskey;"
|
||||
chromedir="&locale.dir;"
|
||||
command="Browser:Back"/>
|
||||
<menuitem id="context-forward"
|
||||
label="&forwardCmd.label;"
|
||||
accesskey="&forwardCmd.accesskey;"
|
||||
chromedir="&locale.dir;"
|
||||
command="Browser:Forward"/>
|
||||
<menuitem id="context-reload"
|
||||
label="&reloadCmd.label;"
|
||||
|
@ -324,7 +324,7 @@
|
||||
</menu>
|
||||
|
||||
<menu id="history-menu"
|
||||
oncommand="var url = event.target.getAttribute('statustext'); if (url) openUILink(url, event, false, true);"
|
||||
oncommand="var url = event.target.getAttribute('statustext'); if (url) { PlacesUtils.markPageAsTyped(url); openUILink(url, event, false, true); }"
|
||||
onclick="checkForMiddleClick(this, event);"
|
||||
label="&historyMenu.label;"
|
||||
accesskey="&historyMenu.accesskey;">
|
||||
@ -338,6 +338,7 @@
|
||||
#else
|
||||
key="goBackKb"
|
||||
#endif
|
||||
chromedir="&locale.dir;"
|
||||
oncommand="BrowserBack(event, true)"
|
||||
onclick="checkForMiddleClick(this, event);">
|
||||
<observes element="Browser:Back" attribute="disabled" />
|
||||
@ -348,6 +349,7 @@
|
||||
#else
|
||||
key="goForwardKb"
|
||||
#endif
|
||||
chromedir="&locale.dir;"
|
||||
oncommand="BrowserForward(event, true)"
|
||||
onclick="checkForMiddleClick(this, event);">
|
||||
<observes element="Browser:Forward" attribute="disabled" />
|
||||
|
@ -1,42 +1,41 @@
|
||||
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 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 the Places Browser Integration
|
||||
*
|
||||
* The Initial Developer of the Original Code is Google Inc.
|
||||
* Portions created by the Initial Developer are Copyright (C) 2006
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
* Ben Goodger <beng@google.com>
|
||||
* Annie Sullivan <annie.sullivan@gmail.com>
|
||||
* Joe Hughes <joe@retrovirus.com>
|
||||
* Asaf Romano <mano@mozilla.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 ***** */
|
||||
# ***** 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 the Places Browser Integration
|
||||
#
|
||||
# The Initial Developer of the Original Code is Google Inc.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2006
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Ben Goodger <beng@google.com>
|
||||
# Annie Sullivan <annie.sullivan@gmail.com>
|
||||
# Joe Hughes <joe@retrovirus.com>
|
||||
# Asaf Romano <mano@mozilla.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 *****
|
||||
|
||||
var PlacesCommandHook = {
|
||||
// nsISupports
|
||||
@ -66,6 +65,9 @@ var PlacesCommandHook = {
|
||||
_blockCommands: function PCH__blockCommands() {
|
||||
for each(var key in this._blockedCommands) {
|
||||
var elt = document.getElementById(key);
|
||||
// make sure not to permanently disable this item (see bug 409155)
|
||||
if (elt.hasAttribute("wasDisabled"))
|
||||
continue;
|
||||
if (elt.getAttribute("disabled") == "true")
|
||||
elt.setAttribute("wasDisabled", "true");
|
||||
else {
|
||||
@ -185,7 +187,7 @@ var PlacesCommandHook = {
|
||||
var title;
|
||||
var description;
|
||||
try {
|
||||
title = webNav.document.title;
|
||||
title = webNav.document.title || url.spec;
|
||||
description = PlacesUtils.getDescriptionFromDocument(webNav.document);
|
||||
}
|
||||
catch (e) { }
|
||||
@ -236,7 +238,7 @@ var PlacesCommandHook = {
|
||||
var itemId = PlacesUtils.getMostRecentBookmarkForURI(linkURI);
|
||||
if (itemId == -1) {
|
||||
var txn = PlacesUtils.ptm.createItem(linkURI, aParent, -1, aTitle);
|
||||
PlacesUtils.ptm.commitTransaction(txn);
|
||||
PlacesUtils.ptm.doTransaction(txn);
|
||||
itemId = PlacesUtils.getMostRecentBookmarkForURI(linkURI);
|
||||
}
|
||||
|
||||
@ -487,11 +489,16 @@ var BookmarksEventHandler = {
|
||||
var openHomePage = document.createElement("menuitem");
|
||||
openHomePage.setAttribute("siteURI", siteURIString);
|
||||
openHomePage.setAttribute("oncommand",
|
||||
"openUILink(this.getAttribute('siteURI'), event);");
|
||||
openHomePage.setAttribute(
|
||||
"label",
|
||||
PlacesUtils.getFormattedString("menuOpenLivemarkOrigin.label",
|
||||
[target.parentNode.getAttribute("label")]));
|
||||
"openUILink(this.getAttribute('siteURI'), event);");
|
||||
// If a user middle-clicks this item we serve the oncommand event
|
||||
// We are using checkForMiddleClick because of Bug 246720
|
||||
// Note: stopPropagation is needed to avoid serving middle-click
|
||||
// with BT_onClick that would open all items in tabs
|
||||
openHomePage.setAttribute("onclick",
|
||||
"checkForMiddleClick(this, event); event.stopPropagation();");
|
||||
openHomePage.setAttribute("label",
|
||||
PlacesUtils.getFormattedString("menuOpenLivemarkOrigin.label",
|
||||
[target.parentNode.getAttribute("label")]));
|
||||
target.appendChild(openHomePage);
|
||||
}
|
||||
|
||||
|
@ -8,7 +8,7 @@ searchbar {
|
||||
}
|
||||
|
||||
#PopupAutoComplete {
|
||||
-moz-binding: url("chrome://browser/content/urlbarBindings.xml#urlbar-result-popup");
|
||||
-moz-binding: url("chrome://browser/content/urlbarBindings.xml#browser-autocomplete-result-popup");
|
||||
}
|
||||
|
||||
#PopupAutoCompleteRichResult {
|
||||
@ -75,3 +75,10 @@ tabbrowser {
|
||||
.tabbrowser-tabs[closebuttons="alltabs"] > .tabbrowser-tab > .tab-close-button {
|
||||
display: -moz-box;
|
||||
}
|
||||
|
||||
/* Hide extension toolbars that neglected to set the proper class */
|
||||
window[chromehidden~="location"][chromehidden~="toolbar"] toolbar:not(.chromeclass-menubar),
|
||||
window[chromehidden~="toolbar"] toolbar:not(.toolbar-primary):not(.chromeclass-menubar)
|
||||
{
|
||||
display: none;
|
||||
}
|
||||
|
@ -77,7 +77,6 @@ const TYPE_XUL = "application/vnd.mozilla.xul+xml";
|
||||
// We use this once, for Clear Private Data
|
||||
const GLUE_CID = "@mozilla.org/browser/browserglue;1";
|
||||
|
||||
var gGlobalHistory = null;
|
||||
var gURIFixup = null;
|
||||
var gCharsetMenu = null;
|
||||
var gLastBrowserCharset = null;
|
||||
@ -320,8 +319,11 @@ const gPopupBlockerObserver = {
|
||||
_reportButton: null,
|
||||
_kIPM: Components.interfaces.nsIPermissionManager,
|
||||
|
||||
onUpdatePageReport: function ()
|
||||
onUpdatePageReport: function (aEvent)
|
||||
{
|
||||
if (aEvent.originalTarget != gBrowser.selectedBrowser)
|
||||
return;
|
||||
|
||||
if (!this._reportButton)
|
||||
this._reportButton = document.getElementById("page-report-button");
|
||||
|
||||
@ -804,6 +806,8 @@ function prepareForStartup()
|
||||
// Note: we need to listen to untrusted events, because the pluginfinder XBL
|
||||
// binding can't fire trusted ones (runs with page privileges).
|
||||
gBrowser.addEventListener("PluginNotFound", gMissingPluginInstaller.newMissingPlugin, true, true);
|
||||
gBrowser.addEventListener("PluginBlocklisted", gMissingPluginInstaller.newMissingPlugin, true, true);
|
||||
gBrowser.addEventListener("NewPluginInstalled", gMissingPluginInstaller.refreshBrowser, false);
|
||||
gBrowser.addEventListener("NewTab", BrowserOpenTab, false);
|
||||
window.addEventListener("AppCommand", HandleAppCommandEvent, true);
|
||||
|
||||
@ -890,14 +894,6 @@ function delayedStartup()
|
||||
gURLBar.setAttribute("enablehistory", "false");
|
||||
}
|
||||
|
||||
if (gURLBar) {
|
||||
try {
|
||||
if (gPrefService.getBoolPref("browser.urlbar.richResults"))
|
||||
gURLBar.setAttribute("autocompletepopup", "PopupAutoCompleteRichResult");
|
||||
} catch (ex) {
|
||||
}
|
||||
}
|
||||
|
||||
gBrowser.addEventListener("pageshow", function(evt) { setTimeout(pageShowEventHandlers, 0, evt); }, true);
|
||||
|
||||
window.addEventListener("keypress", ctrlNumberTabSelection, false);
|
||||
@ -1051,6 +1047,14 @@ function delayedStartup()
|
||||
// do privileged things, without letting error pages have any privilege
|
||||
// themselves.
|
||||
gBrowser.addEventListener("command", BrowserOnCommand, false);
|
||||
|
||||
// Initialize the download manager some time after the app starts so that
|
||||
// auto-resume downloads begin (such as after crashing or quitting with
|
||||
// active downloads) and speeds up the first-load of the download manager UI.
|
||||
// If the user manually opens the download manager before the timeout, the
|
||||
// downloads will start right away, and getting the service again won't hurt.
|
||||
setTimeout(function() Cc["@mozilla.org/download-manager;1"].
|
||||
getService(Ci.nsIDownloadManager), 10000);
|
||||
}
|
||||
|
||||
function BrowserShutdown()
|
||||
@ -1087,14 +1091,6 @@ function BrowserShutdown()
|
||||
|
||||
BrowserOffline.uninit();
|
||||
|
||||
// Store current window position/size into the window attributes
|
||||
// for persistence.
|
||||
var win = document.documentElement;
|
||||
win.setAttribute("x", window.screenX);
|
||||
win.setAttribute("y", window.screenY);
|
||||
win.setAttribute("height", window.outerHeight);
|
||||
win.setAttribute("width", window.outerWidth);
|
||||
|
||||
var windowManager = Components.classes['@mozilla.org/appshell/window-mediator;1'].getService();
|
||||
var windowManagerInterface = windowManager.QueryInterface(Components.interfaces.nsIWindowMediator);
|
||||
var enumerator = windowManagerInterface.getEnumerator(null);
|
||||
@ -2888,17 +2884,9 @@ function addToUrlbarHistory(aUrlToAdd)
|
||||
if (aUrlToAdd.search(/[\x00-\x1F]/) != -1) // don't store bad URLs
|
||||
return;
|
||||
|
||||
if (!gGlobalHistory)
|
||||
gGlobalHistory = Components.classes["@mozilla.org/browser/global-history;2"]
|
||||
.getService(Components.interfaces.nsIBrowserHistory);
|
||||
|
||||
if (!gURIFixup)
|
||||
gURIFixup = Components.classes["@mozilla.org/docshell/urifixup;1"]
|
||||
.getService(Components.interfaces.nsIURIFixup);
|
||||
try {
|
||||
if (aUrlToAdd.indexOf(" ") == -1) {
|
||||
var fixedUpURI = gURIFixup.createFixupURI(aUrlToAdd, 0);
|
||||
gGlobalHistory.markPageAsTyped(fixedUpURI);
|
||||
PlacesUtils.markPageAsTyped(aUrlToAdd);
|
||||
}
|
||||
}
|
||||
catch(ex) {
|
||||
@ -3816,9 +3804,11 @@ nsBrowserAccess.prototype =
|
||||
aWhere = gPrefService.getIntPref("browser.link.open_newwindow");
|
||||
}
|
||||
}
|
||||
var url = aURI ? aURI.spec : "about:blank";
|
||||
switch(aWhere) {
|
||||
case Ci.nsIBrowserDOMWindow.OPEN_NEWWINDOW :
|
||||
// FIXME: Bug 408379. So how come this doesn't send the
|
||||
// referrer like the other loads do?
|
||||
var url = aURI ? aURI.spec : "about:blank";
|
||||
newWindow = openDialog(getBrowserURL(), "_blank", "all,dialog=no", url);
|
||||
break;
|
||||
case Ci.nsIBrowserDOMWindow.OPEN_NEWTAB :
|
||||
@ -3828,16 +3818,18 @@ nsBrowserAccess.prototype =
|
||||
.QueryInterface(Ci.nsIInterfaceRequestor)
|
||||
.getInterface(Ci.nsIDOMWindow);
|
||||
try {
|
||||
if (aOpener) {
|
||||
location = aOpener.location;
|
||||
referrer =
|
||||
Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService)
|
||||
.newURI(location, null, null);
|
||||
if (aURI) {
|
||||
if (aOpener) {
|
||||
location = aOpener.location;
|
||||
referrer =
|
||||
Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService)
|
||||
.newURI(location, null, null);
|
||||
}
|
||||
newWindow.QueryInterface(Ci.nsIInterfaceRequestor)
|
||||
.getInterface(Ci.nsIWebNavigation)
|
||||
.loadURI(aURI.spec, loadflags, referrer, null, null);
|
||||
}
|
||||
newWindow.QueryInterface(Ci.nsIInterfaceRequestor)
|
||||
.getInterface(Ci.nsIWebNavigation)
|
||||
.loadURI(url, loadflags, referrer, null, null);
|
||||
if (!loadInBackground && isExternal)
|
||||
newWindow.focus();
|
||||
} catch(e) {
|
||||
@ -3847,20 +3839,25 @@ nsBrowserAccess.prototype =
|
||||
try {
|
||||
if (aOpener) {
|
||||
newWindow = aOpener.top;
|
||||
location = aOpener.location;
|
||||
referrer =
|
||||
Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService)
|
||||
.newURI(location, null, null);
|
||||
if (aURI) {
|
||||
location = aOpener.location;
|
||||
referrer =
|
||||
Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService)
|
||||
.newURI(location, null, null);
|
||||
|
||||
newWindow.QueryInterface(Ci.nsIInterfaceRequestor)
|
||||
.getInterface(nsIWebNavigation)
|
||||
.loadURI(url, loadflags, referrer, null, null);
|
||||
newWindow.QueryInterface(Ci.nsIInterfaceRequestor)
|
||||
.getInterface(nsIWebNavigation)
|
||||
.loadURI(aURI.spec, loadflags, referrer, null, null);
|
||||
}
|
||||
} else {
|
||||
newWindow = gBrowser.selectedBrowser.docShell
|
||||
.QueryInterface(Ci.nsIInterfaceRequestor)
|
||||
.getInterface(Ci.nsIDOMWindow);
|
||||
getWebNavigation().loadURI(url, loadflags, null, null, null);
|
||||
if (aURI) {
|
||||
getWebNavigation().loadURI(aURI.spec, loadflags, null,
|
||||
null, null);
|
||||
}
|
||||
}
|
||||
if(!gPrefService.getBoolPref("browser.tabs.loadDivertedInBackground"))
|
||||
content.focus();
|
||||
@ -4164,6 +4161,15 @@ function asyncOpenWebPanel(event)
|
||||
var wrapper = null;
|
||||
if (linkNode) {
|
||||
wrapper = linkNode;
|
||||
|
||||
// javascript links should be executed in the current browser
|
||||
if (wrapper.href.substr(0, 11) === "javascript:")
|
||||
return true;
|
||||
|
||||
// data links should be executed in the current browser
|
||||
if (wrapper.href.substr(0, 5) === "data:")
|
||||
return true;
|
||||
|
||||
if (event.button == 0 && !event.ctrlKey && !event.shiftKey &&
|
||||
!event.altKey && !event.metaKey) {
|
||||
// A Web panel's links should target the main content area. Do this
|
||||
@ -4180,12 +4186,6 @@ function asyncOpenWebPanel(event)
|
||||
return true;
|
||||
if (wrapper.getAttribute("onclick"))
|
||||
return true;
|
||||
// javascript links should be executed in the current browser
|
||||
if (wrapper.href.substr(0, 11) === "javascript:")
|
||||
return true;
|
||||
// data links should be executed in the current browser
|
||||
if (wrapper.href.substr(0, 5) === "data:")
|
||||
return true;
|
||||
|
||||
try {
|
||||
urlSecurityCheck(wrapper.href, wrapper.ownerDocument.nodePrincipal);
|
||||
@ -4348,16 +4348,6 @@ function middleMousePaste(event)
|
||||
event.stopPropagation();
|
||||
}
|
||||
|
||||
function makeURLAbsolute( base, url )
|
||||
{
|
||||
// Construct nsIURL.
|
||||
var ioService = Components.classes["@mozilla.org/network/io-service;1"]
|
||||
.getService(Components.interfaces.nsIIOService);
|
||||
var baseURI = ioService.newURI(base, null, null);
|
||||
|
||||
return ioService.newURI(baseURI.resolve(url), null, null).spec;
|
||||
}
|
||||
|
||||
/*
|
||||
* Note that most of this routine has been moved into C++ in order to
|
||||
* be available for all <browser> tags as well as gecko embedding. See
|
||||
@ -4976,7 +4966,7 @@ function getPluginInfo(pluginElement)
|
||||
|
||||
missingPluginInstaller.prototype.installSinglePlugin = function(aEvent){
|
||||
var tabbrowser = getBrowser();
|
||||
var missingPluginsArray = new Object;
|
||||
var missingPluginsArray = {};
|
||||
|
||||
var pluginInfo = getPluginInfo(aEvent.target);
|
||||
missingPluginsArray[pluginInfo.mimetype] = pluginInfo;
|
||||
@ -4984,7 +4974,7 @@ missingPluginInstaller.prototype.installSinglePlugin = function(aEvent){
|
||||
if (missingPluginsArray) {
|
||||
window.openDialog("chrome://mozapps/content/plugins/pluginInstallerWizard.xul",
|
||||
"PFSWindow", "modal,chrome,resizable=yes",
|
||||
{plugins: missingPluginsArray, tab: tabbrowser.mCurrentTab});
|
||||
{plugins: missingPluginsArray, browser: tabbrowser.selectedBrowser});
|
||||
}
|
||||
|
||||
aEvent.preventDefault();
|
||||
@ -5001,7 +4991,8 @@ missingPluginInstaller.prototype.newMissingPlugin = function(aEvent){
|
||||
// plugin. Object tags can, and often do, deal with that themselves,
|
||||
// so don't stomp on the page developers toes.
|
||||
|
||||
if (!(aEvent.target instanceof HTMLObjectElement)) {
|
||||
if (aEvent.type != "PluginBlocklisted" &&
|
||||
!(aEvent.target instanceof HTMLObjectElement)) {
|
||||
aEvent.target.addEventListener("click",
|
||||
gMissingPluginInstaller.installSinglePlugin,
|
||||
false);
|
||||
@ -5023,18 +5014,48 @@ missingPluginInstaller.prototype.newMissingPlugin = function(aEvent){
|
||||
break;
|
||||
}
|
||||
|
||||
var tab = tabbrowser.mTabContainer.childNodes[i];
|
||||
if (!tab.missingPlugins)
|
||||
tab.missingPlugins = {};
|
||||
var browser = tabbrowser.getBrowserAtIndex(i);
|
||||
if (!browser.missingPlugins)
|
||||
browser.missingPlugins = {};
|
||||
|
||||
var pluginInfo = getPluginInfo(aEvent.target);
|
||||
|
||||
tab.missingPlugins[pluginInfo.mimetype] = pluginInfo;
|
||||
browser.missingPlugins[pluginInfo.mimetype] = pluginInfo;
|
||||
|
||||
var browser = tabbrowser.getBrowserAtIndex(i);
|
||||
var notificationBox = gBrowser.getNotificationBox(browser);
|
||||
if (!notificationBox.getNotificationWithValue("missing-plugins")) {
|
||||
var bundle_browser = document.getElementById("bundle_browser");
|
||||
|
||||
// If there is already a missing plugin notification then do nothing
|
||||
if (notificationBox.getNotificationWithValue("missing-plugins"))
|
||||
return;
|
||||
|
||||
var bundle_browser = document.getElementById("bundle_browser");
|
||||
var blockedNotification = notificationBox.getNotificationWithValue("blocked-plugins");
|
||||
const priority = notificationBox.PRIORITY_WARNING_MEDIUM;
|
||||
const iconURL = "chrome://mozapps/skin/plugins/pluginGeneric.png";
|
||||
|
||||
if (aEvent.type == "PluginBlocklisted" && !blockedNotification) {
|
||||
var messageString = bundle_browser.getString("blockedpluginsMessage.title");
|
||||
var buttons = [{
|
||||
label: bundle_browser.getString("blockedpluginsMessage.infoButton.label"),
|
||||
accessKey: bundle_browser.getString("blockedpluginsMessage.infoButton.accesskey"),
|
||||
popup: null,
|
||||
callback: blocklistInfo
|
||||
}, {
|
||||
label: bundle_browser.getString("blockedpluginsMessage.searchButton.label"),
|
||||
accessKey: bundle_browser.getString("blockedpluginsMessage.searchButton.accesskey"),
|
||||
popup: null,
|
||||
callback: pluginsMissing
|
||||
}];
|
||||
|
||||
notificationBox.appendNotification(messageString, "blocked-plugins",
|
||||
iconURL, priority, buttons);
|
||||
}
|
||||
|
||||
if (aEvent.type == "PluginNotFound") {
|
||||
// Cancel any notification about blocklisting
|
||||
if (blockedNotification)
|
||||
blockedNotification.close();
|
||||
|
||||
var messageString = bundle_browser.getString("missingpluginsMessage.title");
|
||||
var buttons = [{
|
||||
label: bundle_browser.getString("missingpluginsMessage.button.label"),
|
||||
@ -5043,30 +5064,44 @@ missingPluginInstaller.prototype.newMissingPlugin = function(aEvent){
|
||||
callback: pluginsMissing
|
||||
}];
|
||||
|
||||
const priority = notificationBox.PRIORITY_WARNING_MEDIUM;
|
||||
const iconURL = "chrome://mozapps/skin/plugins/pluginGeneric.png";
|
||||
notificationBox.appendNotification(messageString, "missing-plugins",
|
||||
iconURL, priority, buttons);
|
||||
}
|
||||
}
|
||||
|
||||
missingPluginInstaller.prototype.closeNotification = function() {
|
||||
var notificationBox = gBrowser.getNotificationBox();
|
||||
missingPluginInstaller.prototype.refreshBrowser = function(aEvent) {
|
||||
var browser = aEvent.target;
|
||||
var notificationBox = gBrowser.getNotificationBox(browser);
|
||||
var notification = notificationBox.getNotificationWithValue("missing-plugins");
|
||||
|
||||
// clear the plugin list, now that at least one plugin has been installed
|
||||
browser.missingPlugins = null;
|
||||
if (notification) {
|
||||
// reset UI
|
||||
notificationBox.removeNotification(notification);
|
||||
}
|
||||
// reload the browser to make the new plugin show.
|
||||
browser.reload();
|
||||
}
|
||||
|
||||
function blocklistInfo()
|
||||
{
|
||||
var formatter = Components.classes["@mozilla.org/toolkit/URLFormatterService;1"]
|
||||
.getService(Components.interfaces.nsIURLFormatter);
|
||||
var url = formatter.formatURLPref("extensions.blocklist.detailsURL");
|
||||
gBrowser.loadOneTab(url, null, null, null, false, false);
|
||||
return true;
|
||||
}
|
||||
|
||||
function pluginsMissing()
|
||||
{
|
||||
// get the urls of missing plugins
|
||||
var tabbrowser = getBrowser();
|
||||
var missingPluginsArray = tabbrowser.mCurrentTab.missingPlugins;
|
||||
var missingPluginsArray = tabbrowser.selectedBrowser.missingPlugins;
|
||||
if (missingPluginsArray) {
|
||||
window.openDialog("chrome://mozapps/content/plugins/pluginInstallerWizard.xul",
|
||||
"PFSWindow", "modal,chrome,resizable=yes", {plugins: missingPluginsArray, tab: tabbrowser.mCurrentTab});
|
||||
"PFSWindow", "modal,chrome,resizable=yes",
|
||||
{plugins: missingPluginsArray, browser: tabbrowser.selectedBrowser});
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -255,7 +255,7 @@
|
||||
chromedir="&locale.dir;"
|
||||
type="autocomplete"
|
||||
autocompletesearch="history"
|
||||
autocompletepopup="PopupAutoComplete"
|
||||
autocompletepopup="PopupAutoCompleteRichResult"
|
||||
completeselectedindex="true"
|
||||
tabscrolling="true"
|
||||
showcommentcolumn="true"
|
||||
|
@ -467,7 +467,7 @@
|
||||
<p id="gecko" class="center">&credit.poweredByGecko;®</p>
|
||||
|
||||
<p class="footnote">
|
||||
&brandFullName;™ &license.part0; ©1998-2007 &license.part1;
|
||||
&brandFullName;™ &license.part0; ©1998-2008 &license.part1;
|
||||
<a href="" link="about:credits" onclick="visitLink(event);">&license.contrib;</a>,
|
||||
&license.part2;
|
||||
<a href="" link="about:license" onclick="visitLink(event);">about:license</a>
|
||||
|
@ -1158,8 +1158,9 @@ nsContextMenu.prototype = {
|
||||
var description = PlacesUtils.getDescriptionFromDocument(doc);
|
||||
|
||||
var descAnno = { name: DESCRIPTION_ANNO, value: description };
|
||||
var txn = PlacesUtils.ptm.createItem(uri, PlacesUtils.bookmarksRootId, -1,
|
||||
title, null, [descAnno]);
|
||||
var txn = PlacesUtils.ptm.createItem(uri,
|
||||
PlacesUtils.bookmarksMenuFolderId,
|
||||
-1, title, null, [descAnno]);
|
||||
PlacesUtils.ptm.doTransaction(txn);
|
||||
itemId = PlacesUtils.getMostRecentBookmarkForURI(uri);
|
||||
}
|
||||
|
@ -557,11 +557,11 @@ function addImage(url, type, alt, elem, isBg)
|
||||
{
|
||||
if (!url)
|
||||
return;
|
||||
if (!(url in gImageHash))
|
||||
if (!gImageHash.hasOwnProperty(url))
|
||||
gImageHash[url] = { };
|
||||
if (!(type in gImageHash[url]))
|
||||
if (!gImageHash[url].hasOwnProperty(type))
|
||||
gImageHash[url][type] = { };
|
||||
if (!(alt in gImageHash[url][type])) {
|
||||
if (!gImageHash[url][type].hasOwnProperty(alt)) {
|
||||
gImageHash[url][type][alt] = gImageView.data.length;
|
||||
try {
|
||||
// open for READ, in non-blocking mode
|
||||
@ -609,6 +609,16 @@ function grabAll(elem)
|
||||
if (elem instanceof HTMLImageElement)
|
||||
addImage(elem.src, gStrings.mediaImg,
|
||||
(elem.hasAttribute("alt")) ? elem.alt : gStrings.notSet, elem, false);
|
||||
#ifdef MOZ_SVG
|
||||
else if (elem instanceof SVGImageElement) {
|
||||
try {
|
||||
// Note: makeURLAbsolute will throw if either the baseURI is not a valid URI
|
||||
// or the URI formed from the baseURI and the URL is not a valid URI
|
||||
var href = makeURLAbsolute(elem.baseURI, elem.href.baseVal);
|
||||
addImage(href, gStrings.mediaImg, "", elem, false);
|
||||
} catch (e) { }
|
||||
}
|
||||
#endif
|
||||
else if (elem instanceof HTMLLinkElement) {
|
||||
if (elem.rel && /\bicon\b/i.test(elem.rel))
|
||||
addImage(elem.href, gStrings.mediaLink, "", elem, false);
|
||||
@ -837,6 +847,14 @@ function makePreview(row)
|
||||
else
|
||||
setItemValue("imagealttext", getValueText(item));
|
||||
|
||||
#ifdef MOZ_SVG
|
||||
if (item instanceof SVGImageElement) {
|
||||
setItemValue("imagetitletext", null);
|
||||
setItemValue("imagelongdesctext", null);
|
||||
setItemValue("imagealttext", null);
|
||||
}
|
||||
#endif
|
||||
|
||||
// get cache info
|
||||
var sourceText = gBundle.getString("generalNotCached");
|
||||
var cacheKey = url.replace(/#.*$/, "");
|
||||
@ -913,6 +931,9 @@ function makePreview(row)
|
||||
|
||||
if ((item instanceof HTMLLinkElement || item instanceof HTMLInputElement ||
|
||||
item instanceof HTMLImageElement ||
|
||||
#ifdef MOZ_SVG
|
||||
item instanceof SVGImageElement ||
|
||||
#endif
|
||||
(item instanceof HTMLObjectElement && /^image\//.test(mimeType)) || isBG) && isProtocolAllowed) {
|
||||
newImage.setAttribute("src", url);
|
||||
physWidth = newImage.width || 0;
|
||||
@ -926,12 +947,19 @@ function makePreview(row)
|
||||
newImage.height = ("height" in item && item.height) || newImage.naturalHeight;
|
||||
}
|
||||
else {
|
||||
// the Width and Height of an HTML tag should not be use for its background image
|
||||
// the Width and Height of an HTML tag should not be used for its background image
|
||||
// (for example, "table" can have "width" or "height" attributes)
|
||||
newImage.width = newImage.naturalWidth;
|
||||
newImage.height = newImage.naturalHeight;
|
||||
}
|
||||
|
||||
#ifdef MOZ_SVG
|
||||
if (item instanceof SVGImageElement) {
|
||||
newImage.width = item.width.baseVal.value;
|
||||
newImage.height = item.height.baseVal.value;
|
||||
}
|
||||
#endif
|
||||
|
||||
width = newImage.width;
|
||||
height = newImage.height;
|
||||
|
||||
|
@ -414,7 +414,7 @@
|
||||
</grid>
|
||||
<spacer flex="1"/>
|
||||
<hbox><!-- Cert button -->
|
||||
<label id="security-view-text" class="fieldLabel"
|
||||
<description id="security-view-text" class="fieldLabel"
|
||||
control="security-view-cert" flex="1"/>
|
||||
<button id="security-view-cert" label="&securityView.certView;"
|
||||
accesskey="&securityView.accesskey;"
|
||||
|
@ -135,10 +135,13 @@ var security = {
|
||||
var wm = Components.classes["@mozilla.org/appshell/window-mediator;1"]
|
||||
.getService(Components.interfaces.nsIWindowMediator);
|
||||
var win = wm.getMostRecentWindow("Browser:Cookies");
|
||||
var eTLDService = Cc["@mozilla.org/network/effective-tld-service;1"].
|
||||
getService(Ci.nsIEffectiveTLDService);
|
||||
var eTLD = eTLDService.getBaseDomainFromHost(this._getSecurityInfo()
|
||||
.hostName);
|
||||
var eTLDService = Components.classes["@mozilla.org/network/effective-tld-service;1"].
|
||||
getService(Components.interfaces.nsIEffectiveTLDService);
|
||||
var eTLD = "";
|
||||
|
||||
if (this._getSecurityInfo().hostName)
|
||||
eTLD = eTLDService.getBaseDomainFromHost(this._getSecurityInfo().hostName);
|
||||
|
||||
if (win) {
|
||||
win.gCookiesWindow.setFilter(eTLD);
|
||||
win.focus();
|
||||
|
@ -210,8 +210,8 @@ Sanitizer.prototype = {
|
||||
{
|
||||
var pwmgr = Components.classes["@mozilla.org/login-manager;1"]
|
||||
.getService(Components.interfaces.nsILoginManager);
|
||||
var logins = pwmgr.getAllLogins({});
|
||||
return (logins.length > 0);
|
||||
var count = pwmgr.countLogins("", "", ""); // count all logins
|
||||
return (count > 0);
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -419,7 +419,7 @@
|
||||
this.mTabBrowser.setIcon(this.mTab, null);
|
||||
|
||||
// changing location, clear out the missing plugins list
|
||||
this.mTab.missingPlugins = null;
|
||||
this.mBrowser.missingPlugins = null;
|
||||
|
||||
if (!this.mBlank && this.mTabBrowser.mCurrentTab == this.mTab) {
|
||||
for (var i = 0; i < this.mTabBrowser.mProgressListeners.length; i++) {
|
||||
@ -708,7 +708,8 @@
|
||||
}
|
||||
|
||||
var updatePageReport = false;
|
||||
if ((this.mCurrentBrowser.pageReport && !newBrowser.pageReport) ||
|
||||
if (!this.mCurrentBrowser ||
|
||||
(this.mCurrentBrowser.pageReport && !newBrowser.pageReport) ||
|
||||
(!this.mCurrentBrowser.pageReport && newBrowser.pageReport))
|
||||
updatePageReport = true;
|
||||
|
||||
@ -1432,6 +1433,9 @@
|
||||
// reset by updateCurrentBrowser.
|
||||
oldBrowser.destroy();
|
||||
|
||||
if (oldBrowser == this.mCurrentBrowser)
|
||||
this.mCurrentBrowser = null;
|
||||
|
||||
// Remove the tab
|
||||
this.mTabContainer.removeChild(oldTab);
|
||||
// invalidate cache, because mTabContainer is about to change
|
||||
|
@ -50,6 +50,7 @@ _TEST_FILES = test_feed_discovery.html \
|
||||
$(NULL)
|
||||
|
||||
_BROWSER_FILES = browser_bug321000.js \
|
||||
browser_bug409481.js \
|
||||
browser_autodiscovery.js \
|
||||
autodiscovery.html \
|
||||
moz.png \
|
||||
|
37
browser/base/content/test/browser_bug409481.js
Normal file
37
browser/base/content/test/browser_bug409481.js
Normal file
@ -0,0 +1,37 @@
|
||||
function test() {
|
||||
waitForExplicitFinish();
|
||||
|
||||
// XXX This looks a bit odd, but is needed to avoid throwing when removing the
|
||||
// event listeners below. See bug 310955.
|
||||
document.getElementById("sidebar").addEventListener("load", function() { setTimeout(openPanelUrl, 100) }, true);
|
||||
toggleSidebar("viewWebPanelsSidebar", true);
|
||||
}
|
||||
|
||||
function openPanelUrl(event) {
|
||||
ok(!document.getElementById("sidebar-box").hidden, "Sidebar showing");
|
||||
|
||||
var sidebar = document.getElementById("sidebar");
|
||||
var root = sidebar.contentDocument.documentElement;
|
||||
ok(root.nodeName != "parsererror", "Sidebar is well formed");
|
||||
|
||||
sidebar.removeEventListener("load", openPanelUrl, true);
|
||||
// XXX See comment above
|
||||
sidebar.contentDocument.addEventListener("load", function() { setTimeout(runTest, 100) }, true);
|
||||
var url = 'data:text/html,<div%20id="test_bug409481">Content!</div>';
|
||||
sidebar.contentWindow.loadWebPanel(url);
|
||||
}
|
||||
|
||||
function runTest(event) {
|
||||
var sidebar = document.getElementById("sidebar");
|
||||
sidebar.contentDocument.removeEventListener("load", runTest, true);
|
||||
|
||||
var browser = sidebar.contentDocument.getElementById("web-panels-browser");
|
||||
var div = browser && browser.contentDocument.getElementById("test_bug409481");
|
||||
ok(div && div.textContent == "Content!", "Sidebar content loaded");
|
||||
|
||||
toggleSidebar("viewWebPanelsSidebar");
|
||||
|
||||
ok(document.getElementById("sidebar-box").hidden, "Sidebar successfully hidden");
|
||||
|
||||
finish();
|
||||
}
|
@ -146,14 +146,15 @@
|
||||
if (url) {
|
||||
nsDragAndDrop.dragDropSecurityCheck(aEvent, aDragSession, url);
|
||||
|
||||
this.value = url;
|
||||
try {
|
||||
gURLBar.value = url;
|
||||
const nsIScriptSecMan = Components.interfaces.nsIScriptSecurityManager;
|
||||
urlSecurityCheck(gURLBar.value,
|
||||
urlSecurityCheck(this.value,
|
||||
gBrowser.contentPrincipal,
|
||||
nsIScriptSecMan.DISALLOW_INHERIT_PRINCIPAL);
|
||||
handleURLBarCommand();
|
||||
} catch (ex) {}
|
||||
Ci.nsIScriptSecurityManager.DISALLOW_INHERIT_PRINCIPAL);
|
||||
} catch (ex) {
|
||||
return;
|
||||
}
|
||||
handleURLBarCommand();
|
||||
}
|
||||
]]></body>
|
||||
</method>
|
||||
@ -266,7 +267,8 @@
|
||||
|
||||
</binding>
|
||||
|
||||
<binding id="urlbar-result-popup" extends="chrome://global/content/bindings/autocomplete.xml#autocomplete-result-popup">
|
||||
<!-- Note: this binding is applied to the autocomplete popup used in the Search bar and in web page content -->
|
||||
<binding id="browser-autocomplete-result-popup" extends="chrome://global/content/bindings/autocomplete.xml#autocomplete-result-popup">
|
||||
<implementation>
|
||||
<method name="openAutocompletePopup">
|
||||
<parameter name="aInput"/>
|
||||
@ -285,31 +287,35 @@
|
||||
<method name="onPopupClick">
|
||||
<parameter name="aEvent"/>
|
||||
<body><![CDATA[
|
||||
// Ignore all right-clicks
|
||||
if (aEvent.button == 2)
|
||||
return;
|
||||
|
||||
var controller = this.view.QueryInterface(Components.interfaces.nsIAutoCompleteController);
|
||||
|
||||
// default action on unmodified left-click
|
||||
// Check for unmodified left-click, and use default behavior
|
||||
if (aEvent.button == 0 && !aEvent.shiftKey && !aEvent.ctrlKey &&
|
||||
!aEvent.altKey && !aEvent.metaKey) {
|
||||
controller.handleEnter();
|
||||
return;
|
||||
}
|
||||
// completely ignore right-clicks
|
||||
else if (aEvent.button != 2) {
|
||||
if (this.mInput._getParentSearchbar) {
|
||||
// handle search bar click
|
||||
var search = controller.getValueAt(this.selectedIndex);
|
||||
var textbox = this.mInput;
|
||||
|
||||
// close the autocomplete popup and copy the selected value to the search box
|
||||
this.closePopup();
|
||||
textbox.value = search;
|
||||
// open the search results according to the clicking subtlety
|
||||
var where = whereToOpenLink(aEvent, false, true);
|
||||
textbox._getParentSearchbar().doSearch(search, where);
|
||||
}
|
||||
else {
|
||||
// everybody else (i.e. browser content) gets unmodified behavior
|
||||
controller.handleEnter();
|
||||
}
|
||||
// Check for middle-click or modified clicks on the search bar
|
||||
var searchBar = BrowserSearch.searchBar;
|
||||
if (searchBar && searchBar.textbox == this.mInput) {
|
||||
// Handle search bar popup clicks
|
||||
var search = controller.getValueAt(this.selectedIndex);
|
||||
|
||||
// close the autocomplete popup and revert the entered search term
|
||||
this.closePopup();
|
||||
controller.handleEscape();
|
||||
|
||||
// Fill in the search bar's value
|
||||
searchBar.value = search;
|
||||
|
||||
// open the search results according to the clicking subtlety
|
||||
var where = whereToOpenLink(aEvent, false, true);
|
||||
searchBar.doSearch(search, where);
|
||||
}
|
||||
]]></body>
|
||||
</method>
|
||||
@ -358,25 +364,29 @@
|
||||
<parameter name="aEvent"/>
|
||||
<body>
|
||||
<![CDATA[
|
||||
// Ignore right-clicks
|
||||
if (aEvent.button == 2)
|
||||
return;
|
||||
|
||||
var controller = this.view.QueryInterface(Components.interfaces.nsIAutoCompleteController);
|
||||
|
||||
// default action on unmodified left-click
|
||||
// Check for unmodified left-click, and use default behavior
|
||||
if (aEvent.button == 0 && !aEvent.shiftKey && !aEvent.ctrlKey &&
|
||||
!aEvent.altKey && !aEvent.metaKey) {
|
||||
controller.handleEnter();
|
||||
return;
|
||||
}
|
||||
// completely ignore right-clicks
|
||||
else if (aEvent.button != 2) {
|
||||
if (gURLBar && this.mInput == gURLBar) {
|
||||
// handle address bar click
|
||||
var url = controller.getValueAt(this.selectedIndex);
|
||||
|
||||
// close the autocomplete popup and revert the entered address
|
||||
this.closePopup();
|
||||
controller.handleEscape();
|
||||
// respect the usual clicking subtleties
|
||||
openUILink(url, aEvent);
|
||||
}
|
||||
// Check for middle-click or modified clicks on the URL bar
|
||||
if (gURLBar && this.mInput == gURLBar) {
|
||||
var url = controller.getValueAt(this.selectedIndex);
|
||||
|
||||
// close the autocomplete popup and revert the entered address
|
||||
this.closePopup();
|
||||
controller.handleEscape();
|
||||
|
||||
// respect the usual clicking subtleties
|
||||
openUILink(url, aEvent);
|
||||
}
|
||||
]]>
|
||||
</body>
|
||||
|
@ -495,6 +495,12 @@ function isElementVisible(aElement)
|
||||
return (bo.height > 0 && bo.width > 0);
|
||||
}
|
||||
|
||||
function makeURLAbsolute(aBase, aUrl)
|
||||
{
|
||||
// Note: IO.newURI(aUri) will throw if aUri is not a valid URI
|
||||
return IO.newURI(aUrl, null, IO.newURI(aBase)).spec;
|
||||
}
|
||||
|
||||
function getBrowserFromContentWindow(aContentWindow)
|
||||
{
|
||||
var browsers = gBrowser.browsers;
|
||||
|
@ -47,6 +47,8 @@
|
||||
%browserDTD;
|
||||
<!ENTITY % textcontextDTD SYSTEM "chrome://global/locale/textcontext.dtd">
|
||||
%textcontextDTD;
|
||||
<!ENTITY % globalDTD SYSTEM "chrome://global/locale/global.dtd">
|
||||
%globalDTD;
|
||||
]>
|
||||
|
||||
<page id="webpanels-window"
|
||||
|
@ -43,4 +43,8 @@ include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
DIRS = public src
|
||||
|
||||
ifdef MOZ_MOCHITEST
|
||||
DIRS += test
|
||||
endif
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
@ -461,9 +461,8 @@ var FeedResultService = {
|
||||
};
|
||||
|
||||
/**
|
||||
* A protocol handler that converts the URIs of Apple's various bogo protocol
|
||||
* schemes into http, as they should be. Mostly, this object just forwards
|
||||
* things through to the HTTP protocol handler.
|
||||
* A protocol handler that attempts to deal with the variant forms of feed:
|
||||
* URIs that are actually either http or https.
|
||||
*/
|
||||
function FeedProtocolHandler(scheme) {
|
||||
this._scheme = scheme;
|
||||
@ -491,6 +490,23 @@ FeedProtocolHandler.prototype = {
|
||||
},
|
||||
|
||||
newURI: function FPH_newURI(spec, originalCharset, baseURI) {
|
||||
// See bug 408599 - feed URIs can be either standard URLs of the form
|
||||
// feed://example.com, in which case the real protocol is http, or nested
|
||||
// URIs of the form feed:realscheme:. When realscheme is either http or
|
||||
// https, we deal with the way that creates a standard URL with the
|
||||
// realscheme as the host by unmangling in newChannel; for others, we fail
|
||||
// rather than let it wind up loading something like www.realscheme.com//foo
|
||||
|
||||
const feedSlashes = "feed://";
|
||||
const feedHttpSlashes = "feed:http://";
|
||||
const feedHttpsSlashes = "feed:https://";
|
||||
const NS_ERROR_MALFORMED_URI = 0x804B000A;
|
||||
|
||||
if (spec.substr(0, feedSlashes.length) != feedSlashes &&
|
||||
spec.substr(0, feedHttpSlashes.length) != feedHttpSlashes &&
|
||||
spec.substr(0, feedHttpsSlashes.length) != feedHttpsSlashes)
|
||||
throw NS_ERROR_MALFORMED_URI;
|
||||
|
||||
var uri =
|
||||
Cc["@mozilla.org/network/standard-url;1"].
|
||||
createInstance(Ci.nsIStandardURL);
|
||||
@ -499,26 +515,28 @@ FeedProtocolHandler.prototype = {
|
||||
return uri;
|
||||
},
|
||||
|
||||
newChannel: function FPH_newChannel(uri) {
|
||||
newChannel: function FPH_newChannel(aUri) {
|
||||
var ios =
|
||||
Cc["@mozilla.org/network/io-service;1"].
|
||||
getService(Ci.nsIIOService);
|
||||
// feed: URIs either start feed://, in which case the real scheme is http:
|
||||
// or feed:http(s)://, (which by now we've changed to feed://realscheme//)
|
||||
var feedSpec = aUri.spec;
|
||||
const httpsChunk = "feed://https//";
|
||||
const httpChunk = "feed://http//";
|
||||
if (uri.spec.substr(0, httpsChunk.length) == httpsChunk)
|
||||
uri.spec = "https://" + uri.spec.substr(httpsChunk.length);
|
||||
else if (uri.spec.substr(0, httpChunk.length) == httpChunk)
|
||||
uri.spec = "http://" + uri.spec.substr(httpChunk.length);
|
||||
if (feedSpec.substr(0, httpsChunk.length) == httpsChunk)
|
||||
feedSpec = "https://" + feedSpec.substr(httpsChunk.length);
|
||||
else if (feedSpec.substr(0, httpChunk.length) == httpChunk)
|
||||
feedSpec = "http://" + feedSpec.substr(httpChunk.length);
|
||||
else
|
||||
uri.scheme = "http";
|
||||
feedSpec = feedSpec.replace(/^feed/, "http");
|
||||
|
||||
var uri = ios.newURI(feedSpec, aUri.originCharset, null);
|
||||
var channel =
|
||||
ios.newChannelFromURI(uri, null).QueryInterface(Ci.nsIHttpChannel);
|
||||
// Set this so we know this is supposed to be a feed
|
||||
channel.setRequestHeader("X-Moz-Is-Feed", "1", false);
|
||||
channel.originalURI = uri;
|
||||
channel.originalURI = aUri;
|
||||
return channel;
|
||||
},
|
||||
|
||||
|
@ -130,8 +130,9 @@ FeedWriter.prototype = {
|
||||
getService(Ci.nsIScriptSecurityManager);
|
||||
const flags = Ci.nsIScriptSecurityManager.DISALLOW_INHERIT_PRINCIPAL;
|
||||
try {
|
||||
secman.checkLoadURIStr(this._window.location.href, uri, flags);
|
||||
// checkLoadURIStr will throw if the link URI should not be loaded per
|
||||
secman.checkLoadURIStrWithPrincipal(this._feedPrincipal, uri, flags);
|
||||
// checkLoadURIStrWithPrincipal will throw if the link URI should not be
|
||||
// loaded, either because our feedURI isn't allowed to load it or per
|
||||
// the rules specified in |flags|, so we'll never "linkify" the link...
|
||||
element.setAttribute(attribute, uri);
|
||||
}
|
||||
@ -776,6 +777,7 @@ FeedWriter.prototype = {
|
||||
_window: null,
|
||||
_document: null,
|
||||
_feedURI: null,
|
||||
_feedPrincipal: null,
|
||||
|
||||
// nsIFeedWriter
|
||||
init: function FW_init(aWindow) {
|
||||
@ -790,6 +792,10 @@ FeedWriter.prototype = {
|
||||
this._window = window;
|
||||
this._document = window.document;
|
||||
|
||||
var secman = Cc["@mozilla.org/scriptsecuritymanager;1"].
|
||||
getService(Ci.nsIScriptSecurityManager);
|
||||
this._feedPrincipal = secman.getCodebasePrincipal(this._feedURI);
|
||||
|
||||
LOG("Subscribe Preview: feed uri = " + this._window.location.href);
|
||||
|
||||
// Set up the subscription UI
|
||||
|
@ -362,8 +362,8 @@ nsFeedSniffer::GetMIMETypeFromContent(nsIRequest* request,
|
||||
// RSS 1.0
|
||||
if (!isFeed) {
|
||||
isFeed = ContainsTopLevelSubstring(dataString, "<rdf:RDF") &&
|
||||
dataString.Find(NS_RDF) &&
|
||||
dataString.Find(NS_RSS);
|
||||
dataString.Find(NS_RDF) != -1 &&
|
||||
dataString.Find(NS_RSS) != -1;
|
||||
}
|
||||
|
||||
// If we sniffed a feed, coerce our internal type
|
||||
|
57
browser/components/feeds/test/Makefile.in
Normal file
57
browser/components/feeds/test/Makefile.in
Normal file
@ -0,0 +1,57 @@
|
||||
# ***** 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
|
||||
# Phil Ringnalda.
|
||||
# Portions created by the Initial Developer are Copyright (C) 2007
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either of 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 *****
|
||||
|
||||
DEPTH = ../../../..
|
||||
topsrcdir = @top_srcdir@
|
||||
srcdir = @srcdir@
|
||||
VPATH = @srcdir@
|
||||
relativesrcdir = browser/components/feeds/test
|
||||
|
||||
include $(DEPTH)/config/autoconf.mk
|
||||
|
||||
MODULE = test_browser_feeds
|
||||
XPCSHELL_TESTS = unit
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
||||
_TEST_FILES = test_bug408328.html \
|
||||
bug408328-data.xml \
|
||||
test_bug368464.html \
|
||||
bug368464-data.xml \
|
||||
$(NULL)
|
||||
|
||||
libs:: $(_TEST_FILES)
|
||||
$(INSTALL) $(foreach f,$^,"$f") $(DEPTH)/_tests/testing/mochitest/tests/$(relativesrcdir)
|
18
browser/components/feeds/test/bug368464-data.xml
Normal file
18
browser/components/feeds/test/bug368464-data.xml
Normal file
@ -0,0 +1,18 @@
|
||||
<?xml version="1.0"?>
|
||||
<rdf:RDF
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns="http://my.netscape.com/rdf/simple/0.9/">
|
||||
<channel>
|
||||
<title>Tinderbox - Firefox</title>
|
||||
<description>Build bustages for Firefox</description>
|
||||
<link>http://tinderbox.mozilla.org/showbuilds.cgi?tree=Firefox</link>
|
||||
</channel>
|
||||
<image>
|
||||
<title>Bad</title>
|
||||
<url>http://tinderbox.mozilla.org/channelflames.gif</url>
|
||||
<link>http://tinderbox.mozilla.org/showbuilds.cgi?tree=Firefox</link>
|
||||
</image>
|
||||
<item><title>The tree is currently closed</title><link>http://tinderbox.mozilla.org/showbuilds.cgi?tree=Firefox</link></item>
|
||||
|
||||
<item><title>MacOSX Darwin 8.8.4 qm-xserve01 dep unit test is in flames</title><link>http://tinderbox.mozilla.org/showbuilds.cgi?tree=Firefox</link></item>
|
||||
</rdf:RDF>
|
63
browser/components/feeds/test/bug408328-data.xml
Normal file
63
browser/components/feeds/test/bug408328-data.xml
Normal file
@ -0,0 +1,63 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom">
|
||||
|
||||
<title>Example Feed</title>
|
||||
<link href="http://example.org/"/>
|
||||
<updated>2003-12-13T18:30:02Z</updated>
|
||||
|
||||
<author>
|
||||
<name>John Doe</name>
|
||||
</author>
|
||||
<id>urn:uuid:60a76c80-d399-11d9-b93C-0003939e0af6</id>
|
||||
|
||||
<entry>
|
||||
|
||||
<title>Good item</title>
|
||||
<link href="http://example.org/first"/>
|
||||
<id>urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6a</id>
|
||||
<updated>2003-12-13T18:30:02Z</updated>
|
||||
|
||||
<summary>Some text.</summary>
|
||||
</entry>
|
||||
|
||||
<entry>
|
||||
|
||||
<title>data: link</title>
|
||||
<link href="data:text/plain,Hi"/>
|
||||
<id>urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6b</id>
|
||||
<updated>2003-12-13T18:30:03Z</updated>
|
||||
|
||||
<summary>Some text.</summary>
|
||||
</entry>
|
||||
|
||||
<entry>
|
||||
|
||||
<title>javascript: link</title>
|
||||
<link href="javascript:alert('Hi')"/>
|
||||
<id>urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6c</id>
|
||||
<updated>2003-12-13T18:30:04Z</updated>
|
||||
|
||||
<summary>Some text.</summary>
|
||||
</entry>
|
||||
|
||||
<entry>
|
||||
|
||||
<title>file: link</title>
|
||||
<link href="file:///var/"/>
|
||||
<id>urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6d</id>
|
||||
<updated>2003-12-13T18:30:05Z</updated>
|
||||
|
||||
<summary>Some text.</summary>
|
||||
</entry>
|
||||
|
||||
<entry>
|
||||
|
||||
<title>chrome: link</title>
|
||||
<link href="chrome://browser/content/browser.js"/>
|
||||
<id>urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6e</id>
|
||||
<updated>2003-12-13T18:30:06Z</updated>
|
||||
|
||||
<summary>Some text.</summary>
|
||||
</entry>
|
||||
|
||||
</feed>
|
34
browser/components/feeds/test/test_bug368464.html
Normal file
34
browser/components/feeds/test/test_bug368464.html
Normal file
@ -0,0 +1,34 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<!--
|
||||
https://bugzilla.mozilla.org/show_bug.cgi?id=368464
|
||||
-->
|
||||
<head>
|
||||
<title>Test that RSS 0.90 isn't sniffed</title>
|
||||
<script type="text/javascript" src="/MochiKit/MochiKit.js"></script>
|
||||
<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
||||
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
|
||||
</head>
|
||||
<body>
|
||||
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=368464">Mozilla Bug 368464</a>
|
||||
<p id="display"><iframe id="testFrame" src="bug368464-data.xml"></iframe></p>
|
||||
<div id="content" style="display: none">
|
||||
|
||||
</div>
|
||||
<pre id="test">
|
||||
<script class="testbody" type="text/javascript">
|
||||
|
||||
/** Test for Bug 368464 **/
|
||||
SimpleTest.waitForExplicitFinish();
|
||||
|
||||
addLoadEvent(function() {
|
||||
netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead");
|
||||
ok($("testFrame").contentDocument.documentElement.id != "feedHandler",
|
||||
"RSS 0.90 shouldn't be sniffed as a feed");
|
||||
});
|
||||
addLoadEvent(SimpleTest.finish);
|
||||
|
||||
</script>
|
||||
</pre>
|
||||
</body>
|
||||
</html>
|
39
browser/components/feeds/test/test_bug408328.html
Normal file
39
browser/components/feeds/test/test_bug408328.html
Normal file
@ -0,0 +1,39 @@
|
||||
<!DOCTYPE HTML>
|
||||
<html>
|
||||
<!--
|
||||
https://bugzilla.mozilla.org/show_bug.cgi?id=408328
|
||||
-->
|
||||
<head>
|
||||
<title>Test feed preview safe-linkification</title>
|
||||
<script type="text/javascript" src="/MochiKit/MochiKit.js"></script>
|
||||
<script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
|
||||
<link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
|
||||
</head>
|
||||
<body>
|
||||
<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=408328">Mozilla Bug 408328</a>
|
||||
<p id="display"><iframe id="testFrame" src="bug408328-data.xml"></iframe></p>
|
||||
<div id="content" style="display: none">
|
||||
|
||||
</div>
|
||||
<pre id="test">
|
||||
<script class="testbody" type="text/javascript">
|
||||
|
||||
/** Test for Bug 408328 **/
|
||||
SimpleTest.waitForExplicitFinish();
|
||||
|
||||
addLoadEvent(function() {
|
||||
netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead");
|
||||
var links = $("testFrame").contentDocument.getElementById("feedContent").getElementsByTagName("a");
|
||||
is(links.length, 5, "wrong number of linked items in feed preview");
|
||||
for (var i = 0; i < links.length; i++) {
|
||||
if (links[i].href)
|
||||
is(links[i].href, "http://example.org/first", "bad linkified item");
|
||||
}
|
||||
});
|
||||
addLoadEvent(SimpleTest.finish);
|
||||
|
||||
</script>
|
||||
</pre>
|
||||
</body>
|
||||
</html>
|
||||
|
5
browser/components/feeds/test/unit/head_feeds.js
Normal file
5
browser/components/feeds/test/unit/head_feeds.js
Normal file
@ -0,0 +1,5 @@
|
||||
const Cc = Components.classes;
|
||||
const Ci = Components.interfaces;
|
||||
const Cr = Components.results;
|
||||
|
||||
var ios = Cc["@mozilla.org/network/io-service;1"].getService(Ci.nsIIOService);
|
49
browser/components/feeds/test/unit/test_355473.js
Normal file
49
browser/components/feeds/test/unit/test_355473.js
Normal file
@ -0,0 +1,49 @@
|
||||
const NS_ERROR_MALFORMED_URI = 0x804B000A;
|
||||
|
||||
function run_test() {
|
||||
var feedFeedURI = ios.newURI("feed://example.com/feed.xml", null, null);
|
||||
var httpFeedURI = ios.newURI("feed:http://example.com/feed.xml", null, null);
|
||||
var httpURI = ios.newURI("http://example.com/feed.xml", null, null);
|
||||
|
||||
var httpsFeedURI =
|
||||
ios.newURI("feed:https://example.com/feed.xml", null, null);
|
||||
var httpsURI = ios.newURI("https://example.com/feed.xml", null, null);
|
||||
|
||||
var feedChannel = ios.newChannelFromURI(feedFeedURI, null);
|
||||
var httpChannel = ios.newChannelFromURI(httpFeedURI, null);
|
||||
var httpsChannel = ios.newChannelFromURI(httpsFeedURI, null);
|
||||
|
||||
// not setting .originalURI to the original URI is naughty
|
||||
do_check_true(feedFeedURI.equals(feedChannel.originalURI));
|
||||
do_check_true(httpFeedURI.equals(httpChannel.originalURI));
|
||||
do_check_true(httpsFeedURI.equals(httpsChannel.originalURI));
|
||||
|
||||
// actually using the horrible mess that's a feed: URI is suicidal
|
||||
do_check_true(httpURI.equals(feedChannel.URI));
|
||||
do_check_true(httpURI.equals(httpChannel.URI));
|
||||
do_check_true(httpsURI.equals(httpsChannel.URI));
|
||||
|
||||
// trying to create a feed URI with something non-http(s) as the inner URL
|
||||
// should fail, until someone fixes bug 408599
|
||||
try {
|
||||
var dataFeedURI = ios.newURI("feed:data:text/xml,<rss/>", null, null);
|
||||
do_throw("Not reached");
|
||||
} catch (e if (e instanceof Ci.nsIException &&
|
||||
e.result == NS_ERROR_MALFORMED_URI)) {
|
||||
// do nothing
|
||||
}
|
||||
try {
|
||||
var ftpFeedURI = ios.newURI("feed:ftp://example.com/feed.xml", null, null);
|
||||
do_throw("Not reached");
|
||||
} catch (e if (e instanceof Ci.nsIException &&
|
||||
e.result == NS_ERROR_MALFORMED_URI)) {
|
||||
// do nothing
|
||||
}
|
||||
try {
|
||||
var fileFeedURI = ios.newURI("feed:file:///var/feed.xml", null, null);
|
||||
do_throw("Not reached");
|
||||
} catch (e if (e instanceof Ci.nsIException &&
|
||||
e.result == NS_ERROR_MALFORMED_URI)) {
|
||||
// do nothing
|
||||
}
|
||||
}
|
@ -316,7 +316,7 @@ static
|
||||
nsOperaProfileMigrator::PrefTransform gTransforms[] = {
|
||||
{ "User Prefs", "Download Directory", _OPM(STRING), "browser.download.dir", _OPM(SetFile), PR_FALSE, -1 },
|
||||
{ nsnull, "Enable Cookies", _OPM(INT), "network.cookie.cookieBehavior", _OPM(SetCookieBehavior), PR_FALSE, -1 },
|
||||
{ nsnull, "Accept Cookies Session Only", _OPM(BOOL), "network.cookie.enableForCurrentSessionOnly", _OPM(SetBool), PR_FALSE, -1 },
|
||||
{ nsnull, "Accept Cookies Session Only", _OPM(BOOL), "network.cookie.lifetimePolicy", _OPM(SetCookieLifetime), PR_FALSE, -1 },
|
||||
{ nsnull, "Allow script to resize window", _OPM(BOOL), "dom.disable_window_move_resize", _OPM(SetBool), PR_FALSE, -1 },
|
||||
{ nsnull, "Allow script to move window", _OPM(BOOL), "dom.disable_window_move_resize", _OPM(SetBool), PR_FALSE, -1 },
|
||||
{ nsnull, "Allow script to raise window", _OPM(BOOL), "dom.disable_window_flip", _OPM(SetBool), PR_FALSE, -1 },
|
||||
@ -353,6 +353,13 @@ nsOperaProfileMigrator::SetCookieBehavior(void* aTransform, nsIPrefBranch* aBran
|
||||
return aBranch->SetIntPref(xform->targetPrefName, val);
|
||||
}
|
||||
|
||||
nsresult
|
||||
nsOperaProfileMigrator::SetCookieLifetime(void* aTransform, nsIPrefBranch* aBranch)
|
||||
{
|
||||
PrefTransform* xform = (PrefTransform*)aTransform;
|
||||
return aBranch->SetIntPref(xform->targetPrefName, xform->boolValue ? 2 : 0);
|
||||
}
|
||||
|
||||
nsresult
|
||||
nsOperaProfileMigrator::SetImageBehavior(void* aTransform, nsIPrefBranch* aBranch)
|
||||
{
|
||||
|
@ -89,6 +89,7 @@ public:
|
||||
|
||||
static nsresult SetFile(void* aTransform, nsIPrefBranch* aBranch);
|
||||
static nsresult SetCookieBehavior(void* aTransform, nsIPrefBranch* aBranch);
|
||||
static nsresult SetCookieLifetime(void* aTransform, nsIPrefBranch* aBranch);
|
||||
static nsresult SetImageBehavior(void* aTransform, nsIPrefBranch* aBranch);
|
||||
static nsresult SetBool(void* aTransform, nsIPrefBranch* aBranch);
|
||||
static nsresult SetWString(void* aTransform, nsIPrefBranch* aBranch);
|
||||
|
@ -638,9 +638,16 @@ PlacesController.prototype = {
|
||||
openSelectedNodeIn: function PC_openSelectedNodeIn(aWhere) {
|
||||
var node = this._view.selectedURINode;
|
||||
if (node && PlacesUtils.checkURLSecurity(node)) {
|
||||
// Check whether the node is a bookmark which should be opened as
|
||||
// a web panel
|
||||
if (aWhere == "current" && PlacesUtils.nodeIsBookmark(node)) {
|
||||
var isBookmark = PlacesUtils.nodeIsBookmark(node);
|
||||
|
||||
if (isBookmark)
|
||||
PlacesUtils.markPageAsFollowedBookmark(node.uri);
|
||||
else
|
||||
PlacesUtils.markPageAsTyped(node.uri);
|
||||
|
||||
// Check whether the node is a bookmark which should be opened as
|
||||
// a web panel
|
||||
if (aWhere == "current" && isBookmark) {
|
||||
if (PlacesUtils.annotations
|
||||
.itemHasAnnotation(node.itemId, LOAD_IN_SIDEBAR_ANNO)) {
|
||||
var w = getTopWin();
|
||||
|
@ -111,8 +111,12 @@ var gEditItemOverlay = {
|
||||
this._initTextField("locationField", this._uri.spec);
|
||||
this._initTextField("tagsField",
|
||||
PlacesUtils.tagging
|
||||
.getTagsForURI(this._uri).join(", "),
|
||||
.getTagsForURI(this._uri, {}).join(", "),
|
||||
false);
|
||||
|
||||
// tags selector
|
||||
this._rebuildTagsSelectorList();
|
||||
|
||||
this._initTextField("keywordField",
|
||||
bms.getKeywordForBookmark(this._itemId));
|
||||
|
||||
@ -428,7 +432,7 @@ var gEditItemOverlay = {
|
||||
},
|
||||
|
||||
_updateTags: function EIO__updateTags() {
|
||||
var currentTags = PlacesUtils.tagging.getTagsForURI(this._uri);
|
||||
var currentTags = PlacesUtils.tagging.getTagsForURI(this._uri, { });
|
||||
var tags = this._getTagsArrayFromTagField();
|
||||
if (tags.length > 0 || currentTags.length > 0) {
|
||||
var tagsToRemove = [];
|
||||
@ -669,6 +673,8 @@ var gEditItemOverlay = {
|
||||
|
||||
_rebuildTagsSelectorList: function EIO__rebuildTagsSelectorList() {
|
||||
var tagsSelector = this._element("tagsSelector");
|
||||
if (tagsSelector.collapsed)
|
||||
return;
|
||||
|
||||
while (tagsSelector.hasChildNodes())
|
||||
tagsSelector.removeChild(tagsSelector.lastChild);
|
||||
@ -693,12 +699,11 @@ var gEditItemOverlay = {
|
||||
expander.className = "expander-up";
|
||||
expander.setAttribute("tooltiptext",
|
||||
expander.getAttribute("tooltiptextup"));
|
||||
|
||||
tagsSelector.collapsed = false;
|
||||
this._rebuildTagsSelectorList();
|
||||
|
||||
// This is a no-op if we've added the listener.
|
||||
tagsSelector.addEventListener("CheckboxStateChange", this, false);
|
||||
tagsSelector.collapsed = false;
|
||||
}
|
||||
else {
|
||||
expander.className = "expander-down";
|
||||
@ -779,7 +784,7 @@ var gEditItemOverlay = {
|
||||
this._initNamePicker(); // for microsummaries
|
||||
this._initTextField("tagsField",
|
||||
PlacesUtils.tagging
|
||||
.getTagsForURI(this._uri).join(", "),
|
||||
.getTagsForURI(this._uri, { }).join(", "),
|
||||
false);
|
||||
this._rebuildTagsSelectorList();
|
||||
}
|
||||
|
@ -288,6 +288,26 @@
|
||||
}
|
||||
},
|
||||
|
||||
itemMoved:
|
||||
function PMV_itemMoved(aItem, aOldParent, aOldIndex, aNewParent,
|
||||
aNewIndex) {
|
||||
// This cannot actually happen yet (see IDL)
|
||||
if (aNewParent != aOldParent);
|
||||
return;
|
||||
|
||||
var popup = this._getPopupForContainer(aNewParent);
|
||||
var index = popup._startMarker + 1 + aNewIndex;
|
||||
var children = popup.childNodes;
|
||||
for (var i = 0; i < children.length; i++) {
|
||||
var menuItem = children[i];
|
||||
if (menuItem.node == aItem) {
|
||||
popup.removeChild(menuItem);
|
||||
popup.insertBefore(menuItem, children[index]);
|
||||
return;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
itemChanged: function PMV_itemChanged(aNode) {
|
||||
// this check can be removed once we fix bug #382397
|
||||
var parentNode = aNode.parent;
|
||||
|
@ -80,6 +80,7 @@ var PlacesOrganizer = {
|
||||
// Set up the advanced query builder UI
|
||||
PlacesQueryBuilder.init();
|
||||
|
||||
window.addEventListener("AppCommand", this, true);
|
||||
#ifdef XP_MACOSX
|
||||
// 1. Map Edit->Find command to the organizer's command
|
||||
var findMenuItem = document.getElementById("menu_find");
|
||||
@ -95,6 +96,34 @@ var PlacesOrganizer = {
|
||||
#endif
|
||||
},
|
||||
|
||||
QueryInterface: function PO_QueryInterface(aIID) {
|
||||
if (aIID.equals(Components.interfaces.nsIDOMEventListener) ||
|
||||
aIID.equals(Components.interfaces.nsISupports))
|
||||
return this;
|
||||
|
||||
throw Components.results.NS_NOINTERFACE;
|
||||
},
|
||||
|
||||
handleEvent: function PO_handleEvent(aEvent) {
|
||||
if (aEvent.type != "AppCommand")
|
||||
return;
|
||||
|
||||
aEvent.stopPropagation();
|
||||
switch (aEvent.command) {
|
||||
case "Back":
|
||||
if (this._backHistory.length > 0)
|
||||
this.back();
|
||||
break;
|
||||
case "Forward":
|
||||
if (this._forwardHistory.length > 0)
|
||||
this.forward();
|
||||
break;
|
||||
case "Search":
|
||||
PlacesSearchBox.findAll();
|
||||
break;
|
||||
}
|
||||
},
|
||||
|
||||
destroy: function PO_destroy() {
|
||||
},
|
||||
|
||||
@ -1614,3 +1643,27 @@ var ViewMenu = {
|
||||
result.sortingMode = sortingMode;
|
||||
}
|
||||
};
|
||||
|
||||
var PlacesToolbar = {
|
||||
// make places toolbar act like menus
|
||||
openedMenuButton: null,
|
||||
|
||||
autoOpenMenu: function (aTarget) {
|
||||
if (this.openedMenuButton && this.openedMenuButton != aTarget &&
|
||||
aTarget.localName == "toolbarbutton" &&
|
||||
(aTarget.type == "menu" || aTarget.type == "menu-button")) {
|
||||
this.openedMenuButton.open = false;
|
||||
aTarget.open = true;
|
||||
}
|
||||
},
|
||||
|
||||
onMenuOpen: function (aTarget) {
|
||||
if (aTarget.parentNode.localName == "toolbarbutton")
|
||||
this.openedMenuButton = aTarget.parentNode;
|
||||
},
|
||||
|
||||
onMenuClose: function (aTarget) {
|
||||
if (aTarget.parentNode.localName == "toolbarbutton")
|
||||
this.openedMenuButton = null;
|
||||
}
|
||||
};
|
||||
|
@ -62,6 +62,8 @@
|
||||
%placesDTD;
|
||||
<!ENTITY % editMenuOverlayDTD SYSTEM "chrome://global/locale/editMenuOverlay.dtd">
|
||||
%editMenuOverlayDTD;
|
||||
<!ENTITY % globalDTD SYSTEM "chrome://global/locale/global.dtd">
|
||||
%globalDTD;
|
||||
]>
|
||||
|
||||
<window id="places"
|
||||
@ -141,17 +143,22 @@
|
||||
</popupset>
|
||||
|
||||
<toolbox id="placesToolbox">
|
||||
<toolbar class="chromeclass-toolbar" id="placesToolbar" align="center">
|
||||
<toolbar class="chromeclass-toolbar" id="placesToolbar" align="center"
|
||||
onmouseover="PlacesToolbar.autoOpenMenu(event.target);"
|
||||
onpopupshowing="PlacesToolbar.onMenuOpen(event.target);"
|
||||
onpopuphidden="PlacesToolbar.onMenuClose(event.target);">
|
||||
<toolbarbutton id="back-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
command="OrganizerCommand:Back"
|
||||
tooltiptext="&backButton.tooltip;"
|
||||
accesskey="&backCmd.accesskey;"
|
||||
chromedir="&locale.dir;"
|
||||
disabled="true"/>
|
||||
|
||||
<toolbarbutton id="forward-button" class="toolbarbutton-1 chromeclass-toolbar-additional"
|
||||
command="OrganizerCommand:Forward"
|
||||
tooltiptext="&forwardButton.tooltip;"
|
||||
accesskey="&forwardCmd.accesskey;"
|
||||
chromedir="&locale.dir;"
|
||||
disabled="true"/>
|
||||
|
||||
<toolbarbutton id="organizeButton" type="menu" label="&organize.label;">
|
||||
|
@ -496,6 +496,37 @@
|
||||
}
|
||||
},
|
||||
|
||||
itemMoved:
|
||||
function TV_V_itemMoved(aItem, aOldParent, aOldIndex, aNewParent,
|
||||
aNewIndex) {
|
||||
// This cannot actually happen yet (see IDL)
|
||||
if (aNewParent != aOldParent);
|
||||
return;
|
||||
|
||||
if (aNewParent == this._self.getResultNode()) {
|
||||
var children = this._self.childNodes;
|
||||
for (var i = 0; i < children.length; i++) {
|
||||
var button = children[i];
|
||||
if (button.node == aItem) {
|
||||
this._self.removeChild(button);
|
||||
this._self.insertBefore(button, children[aNewIndex]);
|
||||
this._self.updateChevron();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
var popup = this._getPopupForContainer(aNewParent);
|
||||
var children = popup.childNodes;
|
||||
for (var i = 0; i < children.length; i++) {
|
||||
var menuItem = children[i];
|
||||
if (menuItem.node == aItem) {
|
||||
popup.removeChild(menuItem);
|
||||
popup.insertBefore(menuItem, children[aNewIndex]);
|
||||
return;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
itemChanged: function TV_V_itemChanged(aNode) {
|
||||
// this check can be removed once we fix bug #382397
|
||||
var parentNode = aNode.parent;
|
||||
@ -1001,16 +1032,16 @@
|
||||
// When the user clicks down on a button, set it as the selection and
|
||||
// tell the controller that we are the active view.
|
||||
//
|
||||
// Sub-menus are handled by the DOMMenuItemActive handler
|
||||
var target = event.target;
|
||||
if (target.parentNode != this)
|
||||
if (target == this)
|
||||
this._selection = this.getResult().root;
|
||||
else if (target.parentNode == this &&
|
||||
(target.localName == "toolbarbutton" ||
|
||||
target.localName == "toolbarseparator"))
|
||||
this._selection = target.node;
|
||||
else // Sub-menus are handled by the DOMMenuItemActive handler
|
||||
return;
|
||||
|
||||
if (target.localName == "toolbarbutton" ||
|
||||
target.localName == "toolbarseparator")
|
||||
this._selection = target.node;
|
||||
else
|
||||
this._selection = this.getResult().root;
|
||||
this._cachedInsertionPoint = undefined;
|
||||
]]></handler>
|
||||
<handler event="draggesture"><![CDATA[
|
||||
|
@ -305,6 +305,21 @@ PlacesTreeView.prototype = {
|
||||
if (aContainer.viewIndex != -1)
|
||||
replaceCount-=1;
|
||||
|
||||
// Persist selection state
|
||||
var nodesToSelect = [];
|
||||
var selection = this.selection;
|
||||
var rc = selection.getRangeCount();
|
||||
for (var rangeIndex = 0; rangeIndex < rc; rangeIndex++) {
|
||||
var min = { }, max = { };
|
||||
selection.getRangeAt(rangeIndex, min, max);
|
||||
var lastIndex = Math.min(max.value, startReplacement + replaceCount -1);
|
||||
if (min.value < startReplacement || min.value > lastIndex)
|
||||
continue;
|
||||
|
||||
for (var nodeIndex = min.value; nodeIndex <= lastIndex; nodeIndex++)
|
||||
nodesToSelect.push(this._visibleElements[nodeIndex]);
|
||||
}
|
||||
|
||||
// Mark the removes as invisible
|
||||
for (var i = 0; i < replaceCount; i++)
|
||||
this._visibleElements[startReplacement + i].viewIndex = -1;
|
||||
@ -314,22 +329,6 @@ PlacesTreeView.prototype = {
|
||||
var toOpenElements = [];
|
||||
this._buildVisibleSection(aContainer, newElements, toOpenElements, startReplacement);
|
||||
|
||||
// Persist selection state
|
||||
var nodesToSelect = [];
|
||||
var selection = this.selection;
|
||||
var rc = selection.getRangeCount();
|
||||
for (var rangeIndex = 0; rangeIndex < rc; rangeIndex++) {
|
||||
var min = { }, max = { };
|
||||
selection.getRangeAt(rangeIndex, min, max);
|
||||
if (min.value > startReplacement + replaceCount)
|
||||
continue;
|
||||
|
||||
for (var nodeIndex = min.value; nodeIndex <= max.value; nodeIndex++) {
|
||||
if (newElements.indexOf(this._visibleElements[nodeIndex]) != -1)
|
||||
nodesToSelect.push(this._visibleElements[nodeIndex]);
|
||||
}
|
||||
}
|
||||
|
||||
// actually update the visible list
|
||||
this._visibleElements =
|
||||
this._visibleElements.slice(0, startReplacement).concat(newElements)
|
||||
@ -377,7 +376,29 @@ PlacesTreeView.prototype = {
|
||||
if (nodesToSelect.length > 0) {
|
||||
for each (var node in nodesToSelect) {
|
||||
var index = node.viewIndex;
|
||||
selection.rangedSelect(index, index, true);
|
||||
|
||||
// if the same node was used (happens on sorting-changes),
|
||||
// just use viewIndex
|
||||
if (index == -1) { // otherwise, try to find an equal node
|
||||
var itemId = node.itemId;
|
||||
if (itemId != 1) { // bookmark-nodes in queries case
|
||||
for (i=0; i < newElements.length && index == -1; i++) {
|
||||
if (newElements[i].itemId == itemId)
|
||||
index = newElements[i].viewIndex;
|
||||
}
|
||||
}
|
||||
else { // history nodes
|
||||
var uri = node.uri;
|
||||
if (uri) {
|
||||
for (i=0; i < newElements.length && index == -1; i++) {
|
||||
if (newElements[i].uri == uri)
|
||||
index = newElements[i].viewIndex;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (index != -1)
|
||||
selection.rangedSelect(index, index, true);
|
||||
}
|
||||
selection.selectEventsSuppressed = false;
|
||||
}
|
||||
@ -472,7 +493,7 @@ PlacesTreeView.prototype = {
|
||||
},
|
||||
|
||||
_sortTypeToColumnType: function PTV__sortTypeToColumnType(aSortType) {
|
||||
switch(aSortType) {
|
||||
switch (aSortType) {
|
||||
case Ci.nsINavHistoryQueryOptions.SORT_BY_TITLE_ASCENDING:
|
||||
return [this.COLUMN_TYPE_TITLE, false];
|
||||
case Ci.nsINavHistoryQueryOptions.SORT_BY_TITLE_DESCENDING:
|
||||
@ -508,6 +529,10 @@ PlacesTreeView.prototype = {
|
||||
return [this.COLUMN_TYPE_LASTMODIFIED, false];
|
||||
case Ci.nsINavHistoryQueryOptions.SORT_BY_LASTMODIFIED_DESCENDING:
|
||||
return [this.COLUMN_TYPE_LASTMODIFIED, true];
|
||||
case Ci.nsINavHistoryQueryOptions.SORT_BY_TAGS_ASCENDING:
|
||||
return [this.COLUMN_TYPE_TAGS, false];
|
||||
case Ci.nsINavHistoryQueryOptions.SORT_BY_TAGS_DESCENDING:
|
||||
return [this.COLUMN_TYPE_TAGS, true];
|
||||
}
|
||||
return [this.COLUMN_TYPE_UNKNOWN, false];
|
||||
},
|
||||
@ -636,7 +661,7 @@ PlacesTreeView.prototype = {
|
||||
itemRemoved: function PTV_itemRemoved(aParent, aItem, aOldIndex) {
|
||||
NS_ASSERT(this._result, "Got a notification but have no result!");
|
||||
if (!this._tree)
|
||||
return; // nothing to do
|
||||
return; // nothing to do
|
||||
|
||||
var oldViewIndex = aItem.viewIndex;
|
||||
if (oldViewIndex < 0)
|
||||
@ -687,6 +712,55 @@ PlacesTreeView.prototype = {
|
||||
this.itemChanged(aParent);
|
||||
},
|
||||
|
||||
/**
|
||||
* Be careful, aOldIndex and aNewIndex specify the index in the
|
||||
* corresponding parent nodes, not the visible indexes.
|
||||
*/
|
||||
itemMoved:
|
||||
function PTV_itemMoved(aItem, aOldParent, aOldIndex, aNewParent, aNewIndex) {
|
||||
NS_ASSERT(this._result, "Got a notification but have no result!");
|
||||
if (!this._tree)
|
||||
return; // nothing to do
|
||||
|
||||
var oldViewIndex = aItem.viewIndex;
|
||||
if (oldViewIndex < 0)
|
||||
return; // item was already invisible, nothing to do
|
||||
|
||||
// this may have been a container, in which case it has a lot of rows
|
||||
var count = this._countVisibleRowsForItem(aItem);
|
||||
|
||||
// Persist selection state
|
||||
var nodesToSelect = [];
|
||||
var selection = this.selection;
|
||||
var rc = selection.getRangeCount();
|
||||
for (var rangeIndex = 0; rangeIndex < rc; rangeIndex++) {
|
||||
var min = { }, max = { };
|
||||
selection.getRangeAt(rangeIndex, min, max);
|
||||
var lastIndex = Math.min(max.value, oldViewIndex + count -1);
|
||||
if (min.value < oldViewIndex || min.value > lastIndex)
|
||||
continue;
|
||||
|
||||
for (var nodeIndex = min.value; nodeIndex <= lastIndex; nodeIndex++)
|
||||
nodesToSelect.push(this._visibleElements[nodeIndex]);
|
||||
}
|
||||
if (nodesToSelect.length > 0)
|
||||
selection.selectEventsSuppressed = true;
|
||||
|
||||
// remove the nodes, let itemInserted restore all of its contents
|
||||
this._visibleElements.splice(oldViewIndex, count);
|
||||
this._tree.rowCountChanged(oldViewIndex, -count);
|
||||
this.itemInserted(aNewParent, aItem, aNewIndex);
|
||||
|
||||
// restore selection
|
||||
if (nodesToSelect.length > 0) {
|
||||
for each (var node in nodesToSelect) {
|
||||
var index = node.viewIndex;
|
||||
selection.rangedSelect(index, index, true);
|
||||
}
|
||||
selection.selectEventsSuppressed = false;
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Be careful, the parameter 'aIndex' here specifies the index in the parent
|
||||
* node of the item, not the visible index.
|
||||
@ -1079,13 +1153,7 @@ PlacesTreeView.prototype = {
|
||||
return "";
|
||||
return node.title || PlacesUtils.getString("noTitle");
|
||||
case this.COLUMN_TYPE_TAGS:
|
||||
if (PlacesUtils.nodeIsURI(node)) {
|
||||
var tagsvc = PlacesUtils.tagging;
|
||||
var uri = PlacesUtils._uri(node.uri);
|
||||
var tags = tagsvc.getTagsForURI(uri, {});
|
||||
return tags.join(", ");
|
||||
}
|
||||
return "";
|
||||
return node.tags;
|
||||
case this.COLUMN_TYPE_URI:
|
||||
if (PlacesUtils.nodeIsURI(node))
|
||||
return node.uri;
|
||||
@ -1170,10 +1238,6 @@ PlacesTreeView.prototype = {
|
||||
if (!this._result)
|
||||
throw Cr.NS_ERROR_UNEXPECTED;
|
||||
|
||||
// Currently cannot sort by tags
|
||||
if (aColumn.id == "tags")
|
||||
return;
|
||||
|
||||
this._enumerateObservers("onCycleHeader", [aColumn]);
|
||||
|
||||
// Sometimes you want a tri-state sorting, and sometimes you don't. This
|
||||
@ -1280,6 +1344,15 @@ PlacesTreeView.prototype = {
|
||||
else
|
||||
newSort = NHQO.SORT_BY_LASTMODIFIED_ASCENDING;
|
||||
|
||||
break;
|
||||
case this.COLUMN_TYPE_TAGS:
|
||||
if (oldSort == NHQO.SORT_BY_TAGS_ASCENDING)
|
||||
newSort = NHQO.SORT_BY_TAGS_DESCENDING;
|
||||
else if (allowTriState && oldSort == NHQO.SORT_BY_TAGS_DESCENDING)
|
||||
newSort = NHQO.SORT_BY_NONE;
|
||||
else
|
||||
newSort = NHQO.SORT_BY_TAGS_ASCENDING;
|
||||
|
||||
break;
|
||||
default:
|
||||
throw Cr.NS_ERROR_INVALID_ARG;
|
||||
|
@ -111,6 +111,12 @@ var PlacesUtils = {
|
||||
getService(Ci.nsINavHistoryService);
|
||||
},
|
||||
|
||||
get globalHistory() {
|
||||
delete this.globalHistory;
|
||||
return this.globalHistory = Cc["@mozilla.org/browser/global-history;2"].
|
||||
getService(Ci.nsIBrowserHistory);
|
||||
},
|
||||
|
||||
/**
|
||||
* The Live Bookmark Service.
|
||||
*/
|
||||
@ -663,9 +669,14 @@ var PlacesUtils = {
|
||||
return aExcludeAnnotations.indexOf(aValue.name) == -1;
|
||||
});
|
||||
}
|
||||
var childTxns = [];
|
||||
if (aData.dateAdded)
|
||||
childTxns.push(this.ptm.editItemDateAdded(null, aData.dateAdded));
|
||||
if (aData.lastModified)
|
||||
childTxns.push(this.ptm.editItemLastModified(null, aData.lastModified));
|
||||
|
||||
return this.ptm.createItem(itemURL, aContainer, aIndex, itemTitle, keyword,
|
||||
annos);
|
||||
annos, childTxns);
|
||||
},
|
||||
|
||||
/**
|
||||
@ -726,9 +737,12 @@ var PlacesUtils = {
|
||||
|
||||
var title = aData.folder.title;
|
||||
var annos = aData.folder.annos;
|
||||
|
||||
return this.ptm.createFolder(title, aContainer, aIndex, annos,
|
||||
getChildItemsTransactions(aData.children));
|
||||
var childItems = getChildItemsTransactions(aData.children);
|
||||
if (aData.folder.dateAdded)
|
||||
childItems.push(this.ptm.editItemDateAdded(null, aData.folder.dateAdded));
|
||||
if (aData.folder.lastModified)
|
||||
childItems.push(this.ptm.editItemLastModified(null, aData.folder.lastModified));
|
||||
return this.ptm.createFolder(title, aContainer, aIndex, annos, childItems);
|
||||
},
|
||||
|
||||
/**
|
||||
@ -1241,6 +1255,29 @@ var PlacesUtils = {
|
||||
return null;
|
||||
},
|
||||
|
||||
/**
|
||||
* By calling this before we visit a URL, we will use TRANSITION_TYPED
|
||||
* as the transition for the visit to that URL (if we don't have a referrer).
|
||||
* This is used when visiting pages from the history menu, history sidebar,
|
||||
* url bar, url autocomplete results, and history searches from the places
|
||||
* organizer. If we don't call this, we'll treat those visits as
|
||||
* TRANSITION_LINK.
|
||||
*/
|
||||
markPageAsTyped: function PU_markPageAsTyped(aURL) {
|
||||
this.globalHistory.markPageAsTyped(this.createFixedURI(aURL));
|
||||
},
|
||||
|
||||
/**
|
||||
* By calling this before we visit a URL, we will use TRANSITION_BOOKMARK
|
||||
* as the transition for the visit to that URL (if we don't have a referrer).
|
||||
* This is used when visiting pages from the bookmarks menu,
|
||||
* personal toolbar, and bookmarks from within the places organizer.
|
||||
* If we don't call this, we'll treat those visits as TRANSITION_LINK.
|
||||
*/
|
||||
markPageAsFollowedBookmark: function PU_markPageAsFollowedBookmark(aURL) {
|
||||
this.history.markPageAsFollowedBookmark(this.createFixedURI(aURL));
|
||||
},
|
||||
|
||||
/**
|
||||
* Allows opening of javascript/data URI only if the given node is
|
||||
* bookmarked (see bug 224521).
|
||||
@ -1552,7 +1589,7 @@ var PlacesUtils = {
|
||||
for (let i = 0; i < contents.childCount; ++i) {
|
||||
let child = contents.getChild(i);
|
||||
if (this.nodeIsURI(child))
|
||||
urls.push(child.uri);
|
||||
urls.push({uri: child.uri, isBookmark: this.nodeIsBookmark(child)});
|
||||
}
|
||||
}
|
||||
else {
|
||||
@ -1568,7 +1605,7 @@ var PlacesUtils = {
|
||||
for (let i = 0; i < aNode.childCount; ++i) {
|
||||
let child = aNode.getChild(i);
|
||||
if (this.nodeIsURI(child))
|
||||
urls.push(child.uri);
|
||||
urls.push({uri: child.uri, isBookmark: this.nodeIsBookmark(child)});
|
||||
}
|
||||
if (!wasOpen)
|
||||
aNode.containerOpen = false;
|
||||
@ -1625,19 +1662,32 @@ var PlacesUtils = {
|
||||
return reallyOpen;
|
||||
},
|
||||
|
||||
_openTabset: function PU__openTabset(aURLs, aEvent) {
|
||||
/** aItemsToOpen needs to be an array of objects of the form:
|
||||
* {uri: string, isBookmark: boolean}
|
||||
*/
|
||||
_openTabset: function PU__openTabset(aItemsToOpen, aEvent) {
|
||||
var urls = [];
|
||||
for each (var item in aItemsToOpen) {
|
||||
if (item.isBookmark)
|
||||
this.markPageAsFollowedBookmark(item.uri);
|
||||
else
|
||||
this.markPageAsTyped(item.uri);
|
||||
|
||||
urls.push(item.uri);
|
||||
}
|
||||
|
||||
var browserWindow = getTopWin();
|
||||
var where = browserWindow ?
|
||||
whereToOpenLink(aEvent, false, true) : "window";
|
||||
if (where == "window") {
|
||||
window.openDialog(getBrowserURL(), "_blank",
|
||||
"chrome,all,dialog=no", aURLs.join("|"));
|
||||
"chrome,all,dialog=no", urls.join("|"));
|
||||
return;
|
||||
}
|
||||
|
||||
var loadInBackground = where == "tabshifted" ? true : false;
|
||||
var replaceCurrentTab = where == "tab" ? false : true;
|
||||
browserWindow.getBrowser().loadTabs(aURLs, loadInBackground,
|
||||
browserWindow.getBrowser().loadTabs(urls, loadInBackground,
|
||||
replaceCurrentTab);
|
||||
},
|
||||
|
||||
@ -1645,14 +1695,16 @@ var PlacesUtils = {
|
||||
var urlsToOpen = this.getURLsForContainerNode(aNode);
|
||||
if (!this._confirmOpenInTabs(urlsToOpen.length))
|
||||
return;
|
||||
|
||||
this._openTabset(urlsToOpen, aEvent);
|
||||
},
|
||||
|
||||
openURINodesInTabs: function PU_openURINodesInTabs(aNodes, aEvent) {
|
||||
var urlsToOpen = [];
|
||||
for (var i=0; i < aNodes.length; i++) {
|
||||
// skip over separators and folders
|
||||
if (this.nodeIsURI(aNodes[i]))
|
||||
urlsToOpen.push(aNodes[i].uri);
|
||||
urlsToOpen.push({uri: aNodes[i].uri, isBookmark: this.nodeIsBookmark(aNodes[i])});
|
||||
}
|
||||
this._openTabset(urlsToOpen, aEvent);
|
||||
},
|
||||
|
@ -52,7 +52,7 @@ interface nsITransaction;
|
||||
* the global scope of a js window.
|
||||
*/
|
||||
|
||||
[scriptable, uuid(89f61a91-c8f7-4abb-b880-895cb9852c35)]
|
||||
[scriptable, uuid(310f22ff-35e3-44b2-8593-08a119933f7e)]
|
||||
interface nsIPlacesTransactionsService : nsITransactionManager
|
||||
{
|
||||
/**
|
||||
@ -286,6 +286,30 @@ interface nsIPlacesTransactionsService : nsITransactionManager
|
||||
nsITransaction editBookmarkMicrosummary(in long long aItemId,
|
||||
in nsIMicrosummary aNewMicrosummary);
|
||||
|
||||
/**
|
||||
* Transaction for editing an item's date added property.
|
||||
*
|
||||
* @param aItemId
|
||||
* id of the item to edit
|
||||
* @param aNewDateAdded
|
||||
* new date added for the item
|
||||
* @returns nsITransaction object
|
||||
*/
|
||||
nsITransaction editItemDateAdded(in long long aItemId,
|
||||
in PRTime aNewDateAdded);
|
||||
|
||||
/**
|
||||
* Transaction for editing an item's last modified time.
|
||||
*
|
||||
* @param aItemId
|
||||
* id of the item to edit
|
||||
* @param aNewLastModified
|
||||
* new last modified date for the item
|
||||
* @returns nsITransaction object
|
||||
*/
|
||||
nsITransaction editItemLastModified(in long long aItemId,
|
||||
in PRTime aNewLastModified);
|
||||
|
||||
/**
|
||||
* Transaction for sorting a folder by name
|
||||
*
|
||||
|
@ -136,6 +136,14 @@ placesTransactionsService.prototype = {
|
||||
return new placesEditBookmarkMicrosummaryTransactions(aID, newMicrosummary);
|
||||
},
|
||||
|
||||
editItemDateAdded: function placesEditItemDateAdded(aID, aNewDateAdded) {
|
||||
return new placesEditItemDateAddedTransaction(aID, aNewDateAdded);
|
||||
},
|
||||
|
||||
editItemLastModified: function placesEditItemLastModified(aID, aNewLastModified) {
|
||||
return new placesEditItemLastModifiedTransaction(aID, aNewLastModified);
|
||||
},
|
||||
|
||||
sortFolderByName: function placesSortFldrByName(aFolderId, aFolderIndex) {
|
||||
return new placesSortFolderByNameTransactions(aFolderId, aFolderIndex);
|
||||
},
|
||||
@ -730,6 +738,54 @@ placesEditBookmarkMicrosummaryTransactions.prototype = {
|
||||
}
|
||||
};
|
||||
|
||||
function placesEditItemDateAddedTransaction(id, newDateAdded) {
|
||||
this.id = id;
|
||||
this._newDateAdded = newDateAdded;
|
||||
this._oldDateAdded = null;
|
||||
this.redoTransaction = this.doTransaction;
|
||||
}
|
||||
|
||||
placesEditItemDateAddedTransaction.prototype = {
|
||||
__proto__: placesBaseTransaction.prototype,
|
||||
|
||||
// to support folders as well
|
||||
get container() { return this.id; },
|
||||
set container(val) { return this.id = val; },
|
||||
|
||||
doTransaction: function PEITT_doTransaction() {
|
||||
this._oldDateAdded = PlacesUtils.bookmarks.getItemDateAdded(this.id);
|
||||
PlacesUtils.bookmarks.setItemDateAdded(this.id, this._newDateAdded);
|
||||
},
|
||||
|
||||
undoTransaction: function PEITT_undoTransaction() {
|
||||
PlacesUtils.bookmarks.setItemDateAdded(this.id, this._oldDateAdded);
|
||||
}
|
||||
};
|
||||
|
||||
function placesEditItemLastModifiedTransaction(id, newLastModified) {
|
||||
this.id = id;
|
||||
this._newLastModified = newLastModified;
|
||||
this._oldLastModified = null;
|
||||
this.redoTransaction = this.doTransaction;
|
||||
}
|
||||
|
||||
placesEditItemLastModifiedTransaction.prototype = {
|
||||
__proto__: placesBaseTransaction.prototype,
|
||||
|
||||
// to support folders as well
|
||||
get container() { return this.id; },
|
||||
set container(val) { return this.id = val; },
|
||||
|
||||
doTransaction: function PEITT_doTransaction() {
|
||||
this._oldLastModified = PlacesUtils.bookmarks.getItemLastModified(this.id);
|
||||
PlacesUtils.bookmarks.setItemLastModified(this.id, this._newLastModified);
|
||||
},
|
||||
|
||||
undoTransaction: function PEITT_undoTransaction() {
|
||||
PlacesUtils.bookmarks.setItemLastModified(this.id, this._oldLastModified);
|
||||
}
|
||||
};
|
||||
|
||||
function placesSortFolderByNameTransactions(aFolderId, aFolderIndex) {
|
||||
this._folderId = aFolderId;
|
||||
this._folderIndex = aFolderIndex;
|
||||
|
@ -113,14 +113,14 @@ var observer = {
|
||||
};
|
||||
bmsvc.addObserver(observer, false);
|
||||
|
||||
// get bookmarks root index
|
||||
var root = bmsvc.bookmarksMenuFolder;
|
||||
|
||||
// index at which items should begin
|
||||
var bmStartIndex = 0;
|
||||
|
||||
// main
|
||||
function run_test() {
|
||||
// get bookmarks root index
|
||||
var root = bmsvc.bookmarksMenuFolder;
|
||||
|
||||
const DESCRIPTION_ANNO = "bookmarkProperties/description";
|
||||
var testDescription = "this is my test description";
|
||||
var annotationService = Cc["@mozilla.org/browser/annotation-service;1"].
|
||||
@ -159,6 +159,7 @@ function run_test() {
|
||||
|
||||
// Create to a folder
|
||||
var txn2a = ptSvc.createFolder("Folder", root, bmStartIndex);
|
||||
ptSvc.doTransaction(txn2a);
|
||||
var fldrId = bmsvc.getChildFolder(root, "Folder");
|
||||
var txn2b = ptSvc.createItem(uri("http://www.example2.com"), fldrId, bmStartIndex, "Testing1b");
|
||||
ptSvc.doTransaction(txn2b);
|
||||
@ -166,7 +167,7 @@ function run_test() {
|
||||
do_check_eq(observer._itemAddedId, b2);
|
||||
do_check_eq(observer._itemAddedIndex, bmStartIndex);
|
||||
do_check_true(bmsvc.isBookmarked(uri("http://www.example2.com")));
|
||||
txn2.undoTransaction();
|
||||
txn2b.undoTransaction();
|
||||
do_check_eq(observer._itemRemovedId, b2);
|
||||
do_check_eq(observer._itemRemovedIndex, bmStartIndex);
|
||||
|
||||
@ -185,30 +186,30 @@ function run_test() {
|
||||
// Moving items between the same folder
|
||||
do_check_eq(observer._itemMovedId, bkmk1Id);
|
||||
do_check_eq(observer._itemMovedOldParent, root);
|
||||
do_check_eq(observer._itemMovedOldIndex, 0);
|
||||
do_check_eq(observer._itemMovedOldIndex, 1);
|
||||
do_check_eq(observer._itemMovedNewParent, root);
|
||||
do_check_eq(observer._itemMovedNewIndex, 1);
|
||||
do_check_eq(observer._itemMovedNewIndex, 2);
|
||||
txn3.undoTransaction();
|
||||
do_check_eq(observer._itemMovedId, bkmk1Id);
|
||||
do_check_eq(observer._itemMovedOldParent, root);
|
||||
do_check_eq(observer._itemMovedOldIndex, 1);
|
||||
do_check_eq(observer._itemMovedOldIndex, 2);
|
||||
do_check_eq(observer._itemMovedNewParent, root);
|
||||
do_check_eq(observer._itemMovedNewIndex, 0);
|
||||
do_check_eq(observer._itemMovedNewIndex, 1);
|
||||
|
||||
// Moving items between different folders
|
||||
var txn3b = ptSvc.moveItem(bkmk1Id, fldrId, -1);
|
||||
txn3b.doTransaction();
|
||||
do_check_eq(observer._itemMovedId, bkmk1Id);
|
||||
do_check_eq(observer._itemMovedOldParent, root);
|
||||
do_check_eq(observer._itemMovedOldIndex, 0);
|
||||
do_check_eq(observer._itemMovedOldIndex, 1);
|
||||
do_check_eq(observer._itemMovedNewParent, fldrId);
|
||||
do_check_eq(observer._itemMovedNewIndex, 2);
|
||||
do_check_eq(observer._itemMovedNewIndex, 1);
|
||||
txn3.undoTransaction();
|
||||
do_check_eq(observer._itemMovedId, bkmk1Id);
|
||||
do_check_eq(observer._itemMovedOldParent, fldrId);
|
||||
do_check_eq(observer._itemMovedOldIndex, 2);
|
||||
do_check_eq(observer._itemMovedOldIndex, 1);
|
||||
do_check_eq(observer._itemMovedNewParent, root);
|
||||
do_check_eq(observer._itemMovedNewIndex, 0);
|
||||
do_check_eq(observer._itemMovedNewIndex, 1);
|
||||
|
||||
// Test Removing a Folder
|
||||
ptSvc.doTransaction(ptSvc.createFolder("Folder2", root, -1));
|
||||
@ -217,22 +218,22 @@ function run_test() {
|
||||
txn4.doTransaction();
|
||||
do_check_eq(observer._itemRemovedId, fldrId2);
|
||||
do_check_eq(observer._itemRemovedFolder, root);
|
||||
do_check_eq(observer._itemRemovedIndex, 2);
|
||||
do_check_eq(observer._itemRemovedIndex, 3);
|
||||
txn4.undoTransaction();
|
||||
do_check_eq(observer._itemAddedId, fldrId2);
|
||||
do_check_eq(observer._itemAddedParent, root);
|
||||
do_check_eq(observer._itemAddedIndex, 2);
|
||||
do_check_eq(observer._itemAddedIndex, 3);
|
||||
|
||||
// Test removing an item
|
||||
var txn5 = ptSvc.removeItem(bkmk2Id);
|
||||
txn5.doTransaction();
|
||||
do_check_eq(observer._itemRemovedId, bkmk2Id);
|
||||
do_check_eq(observer._itemRemovedFolder, root);
|
||||
do_check_eq(observer._itemRemovedIndex, 0);
|
||||
do_check_eq(observer._itemRemovedIndex, 1);
|
||||
txn5.undoTransaction();
|
||||
|
||||
do_check_eq(observer._itemAddedParent, root);
|
||||
do_check_eq(observer._itemAddedIndex, 0);
|
||||
do_check_eq(observer._itemAddedIndex, 1);
|
||||
|
||||
// Test creating a separator
|
||||
var txn6 = ptSvc.createSeparator(root, 1);
|
||||
@ -394,4 +395,22 @@ function run_test() {
|
||||
do_check_eq(annotationService.getItemAnnotation(postDataId, POST_DATA_ANNO), postData);
|
||||
postDataTxn.undoTransaction();
|
||||
do_check_false(annotationService.itemHasAnnotation(postDataId, POST_DATA_ANNO))
|
||||
|
||||
// Test editing item date added
|
||||
var oldAdded = bmsvc.getItemDateAdded(bkmk1Id);
|
||||
var newAdded = Date.now();
|
||||
var eidaTxn = ptSvc.editItemDateAdded(bkmk1Id, newAdded);
|
||||
eidaTxn.doTransaction();
|
||||
do_check_eq(newAdded, bmsvc.getItemDateAdded(bkmk1Id));
|
||||
eidaTxn.undoTransaction();
|
||||
do_check_eq(oldAdded, bmsvc.getItemDateAdded(bkmk1Id));
|
||||
|
||||
// Test editing item last modified
|
||||
var oldModified = bmsvc.getItemLastModified(bkmk1Id);
|
||||
var newModified = Date.now();
|
||||
var eilmTxn = ptSvc.editItemLastModified(bkmk1Id, newModified);
|
||||
eilmTxn.doTransaction();
|
||||
do_check_eq(newModified, bmsvc.getItemLastModified(bkmk1Id));
|
||||
eilmTxn.undoTransaction();
|
||||
do_check_eq(oldModified, bmsvc.getItemLastModified(bkmk1Id));
|
||||
}
|
||||
|
@ -500,8 +500,13 @@ var feedHandlerInfo = {
|
||||
Cc["@mozilla.org/embeddor.implemented/web-content-handler-registrar;1"].
|
||||
getService(Ci.nsIWebContentConverterService),
|
||||
|
||||
_shellSvc: Cc["@mozilla.org/browser/shell-service;1"].
|
||||
getService(Ci.nsIShellService),
|
||||
_shellSvc:
|
||||
#ifdef HAVE_SHELL_SERVICE
|
||||
Cc["@mozilla.org/browser/shell-service;1"].
|
||||
getService(Ci.nsIShellService),
|
||||
#else
|
||||
null,
|
||||
#endif
|
||||
|
||||
|
||||
//**************************************************************************//
|
||||
@ -610,13 +615,15 @@ var feedHandlerInfo = {
|
||||
if (typeof this.__defaultApplicationHandler != "undefined")
|
||||
return this.__defaultApplicationHandler;
|
||||
|
||||
var defaultFeedReader;
|
||||
var defaultFeedReader = null;
|
||||
#ifdef HAVE_SHELL_SERVICE
|
||||
try {
|
||||
defaultFeedReader = this._shellSvc.defaultFeedReader;
|
||||
}
|
||||
catch(ex) {
|
||||
// no default reader
|
||||
}
|
||||
#endif
|
||||
|
||||
if (defaultFeedReader) {
|
||||
let handlerApp = Cc["@mozilla.org/uriloader/local-handler-app;1"].
|
||||
@ -635,6 +642,7 @@ var feedHandlerInfo = {
|
||||
},
|
||||
|
||||
get hasDefaultHandler() {
|
||||
#ifdef HAVE_SHELL_SERVICE
|
||||
try {
|
||||
if (this._shellSvc.defaultFeedReader)
|
||||
return true;
|
||||
@ -642,6 +650,7 @@ var feedHandlerInfo = {
|
||||
catch(ex) {
|
||||
// no default reader
|
||||
}
|
||||
#endif
|
||||
|
||||
return false;
|
||||
},
|
||||
|
@ -65,7 +65,7 @@ var gCookiesWindow = {
|
||||
if (this._view.rowCount > 0)
|
||||
this._tree.view.selection.select(0);
|
||||
|
||||
if ("arguments" in window && window.arguments.length > 0 &&
|
||||
if ("arguments" in window && window.arguments[0] &&
|
||||
window.arguments[0].filterString)
|
||||
this.setFilter(window.arguments[0].filterString);
|
||||
|
||||
|
@ -126,9 +126,10 @@ var gPermissionManager = {
|
||||
var exists = false;
|
||||
for (var i = 0; i < this._permissions.length; ++i) {
|
||||
if (this._permissions[i].rawHost == host) {
|
||||
exists = true;
|
||||
this._permissions[i].capability = capabilityString;
|
||||
this._permissions[i].perm = aCapability;
|
||||
// Avoid calling the permission manager if the capability settings are
|
||||
// the same. Otherwise allow the call to the permissions manager to
|
||||
// update the listbox for us.
|
||||
exists = this._permissions[i].perm == aCapability;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -164,7 +164,6 @@ var gPrivacyPane = {
|
||||
* 1 means allow cookies from the "originating" server only; see
|
||||
* netwerk/cookie/src/nsCookieService.cpp for a hairier definition
|
||||
* 2 means disable all cookies
|
||||
* 3 means use P3P policy to decide, which is probably broken
|
||||
* network.cookie.lifetimePolicy
|
||||
* - determines how long cookies are stored:
|
||||
* 0 means keep cookies until they expire
|
||||
@ -198,7 +197,7 @@ var gPrivacyPane = {
|
||||
writeAcceptCookies: function ()
|
||||
{
|
||||
var checkbox = document.getElementById("acceptCookies");
|
||||
return checkbox.checked ? 0 : 2;
|
||||
return checkbox.checked ? 1 : 2;
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -170,7 +170,8 @@
|
||||
|
||||
<!-- Warning Messages -->
|
||||
<hbox class="bottomBox">
|
||||
<groupbox id="warningMessagesGroup" orient="horizontal" flex="1">
|
||||
<groupbox id="warningMessagesGroup" orient="horizontal" flex="1"
|
||||
align="center">
|
||||
<caption label="&warnings.label;"/>
|
||||
|
||||
<description control="warningSettings" flex="1">&chooseWarnings.label;</description>
|
||||
|
@ -653,8 +653,9 @@
|
||||
// in browser.xul) is hidden to avoid impacting startup / new
|
||||
// window performance. The base binding's openPopup would normally
|
||||
// call the overriden openAutocompletePopup in urlbarBindings.xml's
|
||||
// urlbar-result-popup binding to unhide the popup, but since we're
|
||||
// overriding openPopup we need to unhide the panel ourselves.
|
||||
// browser-autocomplete-result-popup binding to unhide the popup,
|
||||
// but since we're overriding openPopup we need to unhide the panel
|
||||
// ourselves.
|
||||
popup.hidden = false;
|
||||
|
||||
popup.mInput = this;
|
||||
|
@ -54,10 +54,6 @@ const Ci = Components.interfaces;
|
||||
const Cr = Components.results;
|
||||
const Cu = Components.utils;
|
||||
|
||||
const CID = Components.ID("{5280606b-2510-4fe0-97ef-9b5a22eafe6b}");
|
||||
const CONTRACT_ID = "@mozilla.org/browser/sessionstore;1";
|
||||
const CLASS_NAME = "Browser Session Store Service";
|
||||
|
||||
const STATE_STOPPED = 0;
|
||||
const STATE_RUNNING = 1;
|
||||
const STATE_QUITTING = -1;
|
||||
@ -102,6 +98,7 @@ const CAPABILITIES = [
|
||||
|
||||
// module for JSON conversion (needed for the nsISessionStore API)
|
||||
Cu.import("resource://gre/modules/JSON.jsm");
|
||||
Cu.import("resource://gre/modules/XPCOMUtils.jsm");
|
||||
|
||||
function debug(aMsg) {
|
||||
aMsg = ("SessionStore: " + aMsg).replace(/\S{80}/g, "$&\n");
|
||||
@ -115,6 +112,13 @@ function SessionStoreService() {
|
||||
}
|
||||
|
||||
SessionStoreService.prototype = {
|
||||
classDescription: "Browser Session Store Service",
|
||||
contractID: "@mozilla.org/browser/sessionstore;1",
|
||||
classID: Components.ID("{5280606b-2510-4fe0-97ef-9b5a22eafe6b}"),
|
||||
QueryInterface: XPCOMUtils.generateQI([Ci.nsISessionStore,
|
||||
Ci.nsIDOMEventListener,
|
||||
Ci.nsIObserver,
|
||||
Ci.nsISupportsWeakReference]),
|
||||
|
||||
// xul:tab attributes to (re)store (extensions might want to hook in here)
|
||||
xulAttributes: [],
|
||||
@ -419,11 +423,6 @@ SessionStoreService.prototype = {
|
||||
this.restoreWindow(aWindow, this._initialState, this._isCmdLineEmpty(aWindow));
|
||||
delete this._initialState;
|
||||
}
|
||||
|
||||
if (this._lastSessionCrashed) {
|
||||
// restart any interrupted downloads
|
||||
aWindow.setTimeout(this.retryDownloads, 0);
|
||||
}
|
||||
}
|
||||
|
||||
var tabbrowser = aWindow.getBrowser();
|
||||
@ -540,6 +539,12 @@ SessionStoreService.prototype = {
|
||||
* TabPanel reference
|
||||
*/
|
||||
onTabClose: function sss_onTabClose(aWindow, aTab) {
|
||||
// notify the tabbrowser that the tab state will be retrieved for the last time
|
||||
// (so that extension authors can easily set data on soon-to-be-closed tabs)
|
||||
var event = aWindow.document.createEvent("Events");
|
||||
event.initEvent("SSTabClosing", true, false);
|
||||
aTab.dispatchEvent(event);
|
||||
|
||||
var maxTabsUndo = this._prefBranch.getIntPref("sessionstore.max_tabs_undo");
|
||||
// don't update our internal state if we don't have to
|
||||
if (maxTabsUndo == 0) {
|
||||
@ -1755,15 +1760,6 @@ SessionStoreService.prototype = {
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Restart incomplete downloads
|
||||
*/
|
||||
retryDownloads: function sss_retryDownloads() {
|
||||
// The download manager cleans up after itself when it is created.
|
||||
var dlManager = Cc["@mozilla.org/download-manager;1"].
|
||||
getService(Ci.nsIDownloadManager);
|
||||
},
|
||||
|
||||
/* ........ Disk Access .............. */
|
||||
|
||||
/**
|
||||
@ -2068,88 +2064,8 @@ SessionStoreService.prototype = {
|
||||
} else {
|
||||
stream.close();
|
||||
}
|
||||
},
|
||||
|
||||
/* ........ QueryInterface .............. */
|
||||
|
||||
QueryInterface: function(aIID) {
|
||||
if (!aIID.equals(Ci.nsISupports) &&
|
||||
!aIID.equals(Ci.nsIObserver) &&
|
||||
!aIID.equals(Ci.nsISupportsWeakReference) &&
|
||||
!aIID.equals(Ci.nsIDOMEventListener) &&
|
||||
!aIID.equals(Ci.nsISessionStore)) {
|
||||
Components.returnCode = Cr.NS_ERROR_NO_INTERFACE;
|
||||
return null;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
};
|
||||
|
||||
/* :::::::: Service Registration & Initialization ::::::::::::::: */
|
||||
|
||||
/* ........ nsIModule .............. */
|
||||
|
||||
const SessionStoreModule = {
|
||||
|
||||
getClassObject: function(aCompMgr, aCID, aIID) {
|
||||
if (aCID.equals(CID)) {
|
||||
return SessionStoreFactory;
|
||||
}
|
||||
|
||||
Components.returnCode = Cr.NS_ERROR_NOT_REGISTERED;
|
||||
return null;
|
||||
},
|
||||
|
||||
registerSelf: function(aCompMgr, aFileSpec, aLocation, aType) {
|
||||
aCompMgr.QueryInterface(Ci.nsIComponentRegistrar);
|
||||
aCompMgr.registerFactoryLocation(CID, CLASS_NAME, CONTRACT_ID, aFileSpec, aLocation, aType);
|
||||
|
||||
var catMan = Cc["@mozilla.org/categorymanager;1"].
|
||||
getService(Ci.nsICategoryManager);
|
||||
catMan.addCategoryEntry("app-startup", CLASS_NAME, "service," + CONTRACT_ID, true, true);
|
||||
},
|
||||
|
||||
unregisterSelf: function(aCompMgr, aLocation, aType) {
|
||||
aCompMgr.QueryInterface(Ci.nsIComponentRegistrar);
|
||||
aCompMgr.unregisterFactoryLocation(CID, aLocation);
|
||||
|
||||
var catMan = Cc["@mozilla.org/categorymanager;1"].
|
||||
getService(Ci.nsICategoryManager);
|
||||
catMan.deleteCategoryEntry( "app-startup", "service," + CONTRACT_ID, true);
|
||||
},
|
||||
|
||||
canUnload: function(aCompMgr) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
/* ........ nsIFactory .............. */
|
||||
|
||||
const SessionStoreFactory = {
|
||||
|
||||
createInstance: function(aOuter, aIID) {
|
||||
if (aOuter != null) {
|
||||
Components.returnCode = Cr.NS_ERROR_NO_AGGREGATION;
|
||||
return null;
|
||||
}
|
||||
|
||||
return (new SessionStoreService()).QueryInterface(aIID);
|
||||
},
|
||||
|
||||
lockFactory: function(aLock) { },
|
||||
|
||||
QueryInterface: function(aIID) {
|
||||
if (!aIID.equals(Ci.nsISupports) && !aIID.equals(Ci.nsIModule) &&
|
||||
!aIID.equals(Ci.nsIFactory) && !aIID.equals(Ci.nsISessionStore)) {
|
||||
Components.returnCode = Cr.NS_ERROR_NO_INTERFACE;
|
||||
return null;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
};
|
||||
|
||||
function NSGetModule(aComMgr, aFileSpec) {
|
||||
return SessionStoreModule;
|
||||
}
|
||||
function NSGetModule(aComMgr, aFileSpec)
|
||||
XPCOMUtils.generateModule([SessionStoreService]);
|
||||
|
@ -538,3 +538,12 @@ res/html/gopher-sound.gif
|
||||
res/html/gopher-telnet.gif
|
||||
res/html/gopher-text.gif
|
||||
res/html/gopher-unknown.gif
|
||||
res/fonts/mathfontCMEX10.properties
|
||||
res/fonts/mathfontCMSY10.properties
|
||||
res/fonts/mathfontMath1.properties
|
||||
res/fonts/mathfontMath2.properties
|
||||
res/fonts/mathfontMath4.properties
|
||||
res/fonts/mathfontMTExtra.properties
|
||||
res/fonts/mathfontPUA.properties
|
||||
res/fonts/mathfontSymbol.properties
|
||||
|
||||
|
@ -4,7 +4,7 @@
|
||||
<!ENTITY aboutLink "< About &brandFullName;">
|
||||
<!ENTITY aboutLink.accesskey "A">
|
||||
<!ENTITY aboutVersion "version">
|
||||
<!ENTITY copyrightText "©1998-2007 Contributors. All Rights Reserved. Firefox and the
|
||||
<!ENTITY copyrightText "©1998-2008 Contributors. All Rights Reserved. Firefox and the
|
||||
Firefox logos are trademarks of the Mozilla Foundation. All rights
|
||||
reserved. Some trademark rights used under license from The
|
||||
Charlton Company.">
|
||||
|
@ -313,14 +313,14 @@
|
||||
<!ENTITY pageStylePersistentOnly.label "Basic Page Style">
|
||||
<!ENTITY pageStylePersistentOnly.accesskey "b">
|
||||
|
||||
<!ENTITY pageReportIcon.tooltip "Change popup blocking settings for this web site">
|
||||
<!ENTITY pageReportIcon.tooltip "Change pop-up blocking settings for this web site">
|
||||
|
||||
<!ENTITY allowPopups.accesskey "p">
|
||||
<!-- On Windows we use the term "Options" to describe settings, but
|
||||
on Linux and Mac OS X we use "Preferences" - carry that distinction
|
||||
over into this string, which is used in the "popup blocked" info bar . -->
|
||||
<!ENTITY editPopupSettingsUnix.label "Edit Popup Blocker Preferences…">
|
||||
<!ENTITY editPopupSettings.label "Edit Popup Blocker Options…">
|
||||
<!ENTITY editPopupSettingsUnix.label "Edit Pop-up Blocker Preferences…">
|
||||
<!ENTITY editPopupSettings.label "Edit Pop-up Blocker Options…">
|
||||
<!ENTITY editPopupSettings.accesskey "E">
|
||||
<!ENTITY dontShowMessage.accesskey "D">
|
||||
|
||||
|
@ -31,16 +31,16 @@ xpinstallDisabledMessageLocked=Software installation has been disabled by your s
|
||||
xpinstallDisabledMessage=Software installation is currently disabled. Click Enable and try again.
|
||||
xpinstallDisabledButton=Enable
|
||||
xpinstallDisabledButton.accesskey=n
|
||||
popupWarning=%S prevented this site from opening a popup window.
|
||||
popupWarningMultiple=%S prevented this site from opening %S popup windows.
|
||||
popupWarning=%S prevented this site from opening a pop-up window.
|
||||
popupWarningMultiple=%S prevented this site from opening %S pop-up windows.
|
||||
popupWarningButton=Options
|
||||
popupWarningButton.accesskey=O
|
||||
popupWarningButtonUnix=Preferences
|
||||
popupWarningButtonUnix.accesskey=P
|
||||
popupAllow=Allow popups for %S
|
||||
popupBlock=Block popups for %S
|
||||
popupWarningDontShowFromMessage=Don't show this message when popups are blocked
|
||||
popupWarningDontShowFromStatusbar=Don't show info message when popups are blocked
|
||||
popupAllow=Allow pop-ups for %S
|
||||
popupBlock=Block pop-ups for %S
|
||||
popupWarningDontShowFromMessage=Don't show this message when pop-ups are blocked
|
||||
popupWarningDontShowFromStatusbar=Don't show info message when pop-ups are blocked
|
||||
popupShowPopupPrefix=Show '%S'
|
||||
|
||||
imageBlockedWarning=%S will now always block images from %S.
|
||||
@ -52,6 +52,11 @@ undo.accessKey=U
|
||||
missingpluginsMessage.title=Additional plugins are required to display all the media on this page.
|
||||
missingpluginsMessage.button.label=Install Missing Plugins…
|
||||
missingpluginsMessage.button.accesskey=I
|
||||
blockedpluginsMessage.title=Some plugins required by this page have been blocked for your protection.
|
||||
blockedpluginsMessage.infoButton.label=Details…
|
||||
blockedpluginsMessage.infoButton.accesskey=D
|
||||
blockedpluginsMessage.searchButton.label=Update Plugins…
|
||||
blockedpluginsMessage.searchButton.accesskey=U
|
||||
|
||||
# Sanitize
|
||||
sanitizeWithPromptLabel=Clear Private Data…
|
||||
|
@ -95,7 +95,7 @@
|
||||
<!ENTITY permBlock "Block">
|
||||
<!ENTITY permissionsFor "Permissions for:">
|
||||
<!ENTITY permImage "Load Images">
|
||||
<!ENTITY permPopup "Open Popup Windows">
|
||||
<!ENTITY permPopup "Open Pop-up Windows">
|
||||
<!ENTITY permCookie "Set Cookies">
|
||||
<!ENTITY permInstall "Install Extensions or Themes">
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!ENTITY caption.label "Blocked Popups">
|
||||
<!ENTITY caption.label "Blocked Pop-ups">
|
||||
|
||||
<!ENTITY intro.label "The following pages were prevented from displaying
|
||||
unrequested popup windows:">
|
||||
unrequested pop-up windows:">
|
||||
|
||||
<!ENTITY done.label "Done">
|
||||
<!ENTITY done.accesskey "D">
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!ENTITY startDescription.label "A web site has attempted to open a popup window without your permission. &brandShortName; has automatically closed the popup window. Whenever &brandShortName; blocks these popups, you will see an icon on the status bar.">
|
||||
<!ENTITY startDescription.label "A web site has attempted to open a pop-up window without your permission. &brandShortName; has automatically closed the pop-up window. Whenever &brandShortName; blocks these pop-ups, you will see an icon on the status bar.">
|
||||
|
||||
<!ENTITY endDescription.label "You can click on this icon to see which sites &brandShortName; blocked and to allow those sites to open popups if they are required for the site to function correctly.">
|
||||
<!ENTITY endDescription.label "You can click on this icon to see which sites &brandShortName; blocked and to allow those sites to open pop-ups if they are required for the site to function correctly.">
|
||||
|
||||
<!ENTITY caption.label "About Popup Blocking">
|
||||
<!ENTITY caption.label "About Pop-up Blocking">
|
||||
|
||||
<!ENTITY done.label "Done">
|
||||
|
@ -15,8 +15,8 @@ cookiepermissionstext=You can specify which web sites are always or never allowe
|
||||
cookiepermissionstitle=Exceptions - Cookies
|
||||
addonspermissionstext=You can specify which web sites are allowed to install add-ons. Type the exact address of the site you want to allow and then click Allow.
|
||||
addons_permissions_title=Allowed Sites - Add-ons Installation
|
||||
popuppermissionstext=You can specify which web sites are allowed to open popup windows. Type the exact address of the site you want to allow and then click Allow.
|
||||
popuppermissionstitle=Allowed Sites - Popups
|
||||
popuppermissionstext=You can specify which web sites are allowed to open pop-up windows. Type the exact address of the site you want to allow and then click Allow.
|
||||
popuppermissionstitle=Allowed Sites - Pop-ups
|
||||
imagepermissionstext=You can specify which web sites are allowed to load images. Type the exact address of the site you want to manage and then click Block or Allow.
|
||||
imagepermissionstitle=Exceptions - Images
|
||||
invalidURI=Please enter a valid hostname
|
||||
|
@ -211,10 +211,10 @@ Contributors:
|
||||
|
||||
<h2 id="controlling_web_content">Controlling Web Content</h2>
|
||||
|
||||
<h3 id="blocking_popup_windows">Blocking Popup Windows</h3>
|
||||
<h3 id="blocking_popup_windows">Blocking Pop-up Windows</h3>
|
||||
|
||||
<p>See <a href="popup.xhtml">Controlling Popups</a> for information on
|
||||
blocking popup windows.</p>
|
||||
<p>See <a href="popup.xhtml">Controlling Pop-ups</a> for information on
|
||||
blocking pop-up windows.</p>
|
||||
|
||||
<h3 id="turning_off_java_applets">Turning Off Java Applets</h3>
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
||||
<nc:subheadings rdf:resource="#prefs-tree"/>
|
||||
</rdf:Description>
|
||||
</rdf:li>
|
||||
<rdf:li> <rdf:Description ID="popup-blocker" nc:name="Controlling Popups" nc:link="popup.xhtml"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="popup-blocker" nc:name="Controlling Pop-ups" nc:link="popup.xhtml"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="cookies" nc:name="Managing Cookies" nc:link="cookies.xhtml"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="tabbed-browsing" nc:name="Tabbed Browsing" nc:link="tabbed_browsing.xhtml"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="firebird-keyboard-shortcuts" nc:name="Keyboard Shortcuts" nc:link="shortcuts.xhtml"/> </rdf:li>
|
||||
@ -137,9 +137,9 @@
|
||||
<rdf:Description about="#popup-blocker">
|
||||
<nc:subheadings>
|
||||
<rdf:Seq>
|
||||
<rdf:li> <rdf:Description ID="popup-blocker-what-are-popups" nc:name="What are Popups?" nc:link="popup.xhtml#what_are_popups"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="popup-blocker-prefs-win" nc:name="Popup Blocker Options" nc:link="popup.xhtml#popup_blocker_preferences" nc:platform="win os2"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="popup-blocker-prefs-unix" nc:name="Popup Blocker Preferences" nc:link="popup.xhtml#popup_blocker_preferences" nc:platform="unix mac"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="popup-blocker-what-are-popups" nc:name="What are Pop-ups?" nc:link="popup.xhtml#what_are_popups"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="popup-blocker-prefs-win" nc:name="Pop-up Blocker Options" nc:link="popup.xhtml#popup_blocker_preferences" nc:platform="win os2"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="popup-blocker-prefs-unix" nc:name="Pop-up Blocker Preferences" nc:link="popup.xhtml#popup_blocker_preferences" nc:platform="unix mac"/> </rdf:li>
|
||||
</rdf:Seq>
|
||||
</nc:subheadings>
|
||||
</rdf:Description>
|
||||
@ -215,7 +215,7 @@
|
||||
<rdf:Description about="#a11y-web-content">
|
||||
<nc:subheadings>
|
||||
<rdf:Seq>
|
||||
<rdf:li> <rdf:Description ID="a11y-popup-windows" nc:name="Blocking Popup Windows" nc:link="accessibility.xhtml#blocking_popup_windows"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="a11y-popup-windows" nc:name="Blocking Pop-up Windows" nc:link="accessibility.xhtml#blocking_popup_windows"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="a11y-java" nc:name="Turning Off Java Applets" nc:link="accessibility.xhtml#turning_off_java_applets"/> </rdf:li>
|
||||
<rdf:li> <rdf:Description ID="a11y-javascript" nc:name="Restricting JavaScript Behavior" nc:link="accessibility.xhtml#restricting_javascript_behavior"/> </rdf:li>
|
||||
</rdf:Seq>
|
||||
|
@ -91,7 +91,7 @@
|
||||
your home page. For more information see <a
|
||||
href="tabbed_browsing.xhtml">Tabbed Browsing</a>.</li>
|
||||
<li><strong>Pop-up Window Controls</strong>: Lets you allow or suppress both
|
||||
popup and popunder windows.</li>
|
||||
pop-up and pop-under windows.</li>
|
||||
<li><strong>Cookie Manager</strong>: Lets you change what &brandShortName; will
|
||||
do when accepting cookies.</li>
|
||||
<li><strong>Download Manager</strong>: Organizes your downloads by storing
|
||||
|
@ -40,4 +40,4 @@
|
||||
|
||||
<!-- Copyright years -->
|
||||
|
||||
<!ENTITY copyright.years '2003-2007'>
|
||||
<!ENTITY copyright.years '2003-2008'>
|
||||
|
@ -12,69 +12,69 @@ Contributors:
|
||||
-->
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>Controlling Popups</title>
|
||||
<title>Controlling Pop-ups</title>
|
||||
<link rel="stylesheet" type="text/css" href="chrome://help/skin/helpFileLayout.css"/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<h1>Controlling Popups</h1>
|
||||
<h1>Controlling Pop-ups</h1>
|
||||
<p>This document explains all of the &pref.plural; available in &brandFullName;
|
||||
for controlling popups.</p>
|
||||
for controlling pop-ups.</p>
|
||||
|
||||
<div class="contentsBox">
|
||||
In this section:
|
||||
<ul>
|
||||
<li><a href="#what_are_popups">What are Popups?</a></li>
|
||||
<li><a href="#popup_blocker_preferences">Popup Blocker &pref.pluralCaps;</a></li>
|
||||
<li><a href="#what_are_popups">What are Pop-ups?</a></li>
|
||||
<li><a href="#popup_blocker_preferences">Pop-up Blocker &pref.pluralCaps;</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<h2 id="what_are_popups">What are Popups?</h2>
|
||||
<p>Popup windows, or popups, are windows that appear automatically without your
|
||||
permission. They vary in size but usually don't cover the whole screen. Some popups
|
||||
<h2 id="what_are_popups">What are Pop-ups?</h2>
|
||||
<p>Pop-up windows, or pop-ups, are windows that appear automatically without your
|
||||
permission. They vary in size but usually don't cover the whole screen. Some pop-ups
|
||||
open on top of the current &brandShortName; window, while others appear
|
||||
underneath &brandShortName; (popunders).</p>
|
||||
underneath &brandShortName; (pop-unders).</p>
|
||||
|
||||
<p>&brandShortName; allows you to control both popups and popunders through the
|
||||
<p>&brandShortName; allows you to control both pop-ups and popunders through the
|
||||
<a href="prefs.xhtml#content_options">Content panel</a> in &pref.pluralCaps;.
|
||||
Popup blocking is turned on by default, so you don't have to worry about enabling it
|
||||
to prevent popups from appearing in &brandShortName;.</p>
|
||||
Pop-up blocking is turned on by default, so you don't have to worry about enabling it
|
||||
to prevent pop-ups from appearing in &brandShortName;.</p>
|
||||
|
||||
<p>When blocking a popup, &brandShortName; displays an information bar, as well
|
||||
<p>When blocking a pop-up, &brandShortName; displays an information bar, as well
|
||||
as an icon <img src="chrome://browser/skin/Info.png" width="16" height="16"
|
||||
alt=""/> in the status bar. When you click either the <em>&pref.pluralCaps;</em>
|
||||
button in the information bar or the icon in the status bar, a menu is displayed
|
||||
with the following choices:</p>
|
||||
|
||||
<ul>
|
||||
<li>Allow/Block popups for this site</li>
|
||||
<li>Edit <a href="#popup_blocker_preferences">Popup Blocker
|
||||
<li>Allow/Block pop-ups for this site</li>
|
||||
<li>Edit <a href="#popup_blocker_preferences">Pop-up Blocker
|
||||
&pref.pluralCaps;…</a></li>
|
||||
<li>Don't show this message (info message) when popups are blocked</li>
|
||||
<li>(show a blocked popup)</li>
|
||||
<li>Don't show this message (info message) when pop-ups are blocked</li>
|
||||
<li>(show a blocked pop-up)</li>
|
||||
</ul>
|
||||
|
||||
<p><strong>Blocking popups may interfere with some web sites</strong>: Some web sites,
|
||||
including some banking sites, use popups for important features. Blocking all popups
|
||||
disables such features. To allow specific web sites to use popups, while blocking
|
||||
<p><strong>Blocking pop-ups may interfere with some web sites</strong>: Some web sites,
|
||||
including some banking sites, use pop-ups for important features. Blocking all pop-ups
|
||||
disables such features. To allow specific web sites to use pop-ups, while blocking
|
||||
all others, you can add specific web sites to the list of allowed sites.</p>
|
||||
|
||||
<p><strong>Blocking popups doesn't always work</strong>: Although &brandShortName; blocks most
|
||||
popups, some web sites may show popups using uncovered methods, even when blocked.</p>
|
||||
<p><strong>Blocking pop-ups doesn't always work</strong>: Although &brandShortName; blocks most
|
||||
pop-ups, some web sites may show pop-ups using uncovered methods, even when blocked.</p>
|
||||
|
||||
<h2 id="popup_blocker_preferences">Popup Blocker &pref.pluralCaps;</h2>
|
||||
<h2 id="popup_blocker_preferences">Pop-up Blocker &pref.pluralCaps;</h2>
|
||||
|
||||
<p>The Popup Blocker &pref.pluralCaps; are located in the <a
|
||||
<p>The Pop-up Blocker &pref.pluralCaps; are located in the <a
|
||||
href="prefs.xhtml#content_options">Content panel</a> of &pref.menuPath;.</p>
|
||||
|
||||
<p>From there, you can do the following things:</p>
|
||||
|
||||
<ul>
|
||||
<li><strong>Block pop-up windows</strong>: Deselect this &pref.singular; to
|
||||
disable the popup blocker altogether.</li>
|
||||
disable the pop-up blocker altogether.</li>
|
||||
<li><strong>Exceptions dialog</strong>: This is a list of sites that you want to allow
|
||||
to display popups. The dialog has the following choices:
|
||||
to display pop-ups. The dialog has the following choices:
|
||||
<ul>
|
||||
<li><strong>Allow</strong>: Click this to add a web site to the exceptions list.</li>
|
||||
<li><strong>Remove Site</strong>: Click this to remove a web site from the exceptions list.</li>
|
||||
@ -84,9 +84,9 @@ popups, some web sites may show popups using uncovered methods, even when blocke
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<p><strong>Note</strong>: Blocking popups may not always work and may interfere with
|
||||
some web sites. For more information about blocking popups, see
|
||||
<a href="#what_are_popups">What are Popups</a>.</p>
|
||||
<p><strong>Note</strong>: Blocking pop-ups may not always work and may interfere with
|
||||
some web sites. For more information about blocking pop-ups, see
|
||||
<a href="#what_are_popups">What are Pop-ups</a>.</p>
|
||||
|
||||
<div class="contentsBox"><em>12 September 2005</em></div>
|
||||
<p>Copyright © ©right.years; Contributors to the Mozilla Help Viewer Project.</p>
|
||||
|
@ -18,7 +18,7 @@
|
||||
<li><Description nc:name="Anti-Phishing Preferences" nc:link="prefs.xhtml#phishing" nc:platform="unix mac"/></li>
|
||||
<li><Description nc:name="authentication (definition)" nc:link="glossary.xhtml#authentication"/></li>
|
||||
<li><Description nc:name="Back Button" nc:link="using_firebird.xhtml#retracing_your_steps"/></li>
|
||||
<li><Description nc:name="Block Popups" nc:link="popup.xhtml"/></li>
|
||||
<li><Description nc:name="Block Pop-ups" nc:link="popup.xhtml"/></li>
|
||||
<li><Description nc:name="bookmark (definition)" nc:link="glossary.xhtml#bookmark"/></li>
|
||||
<li><Description nc:name="Bookmarks Toolbar (definition)" nc:link="glossary.xhtml#Bookmarks_Toolbar"/></li>
|
||||
<li><Description nc:name="Browsing" nc:link="using_firebird.xhtml#navigating_web_pages"/></li>
|
||||
|
@ -174,7 +174,7 @@ Contributors:
|
||||
<li>Select (highlight) any words in a web page.</li>
|
||||
<li><span class="noMac">Right-click</span><span class="mac">Press &ctrlKey;,
|
||||
click the mouse button,</span> and choose <em>Search [Search Engine] for
|
||||
"[your selected words]"</em> from the popup menu.</li>
|
||||
"[your selected words]"</em> from the pop-up menu.</li>
|
||||
</ol>
|
||||
|
||||
<p>&brandShortName; opens a new tab and uses the currently selected Search
|
||||
@ -235,7 +235,7 @@ Contributors:
|
||||
<ol>
|
||||
<li>Position the pointer over the link or image.</li>
|
||||
<li><span class="noMac">Right-click</span><span class="mac">Press &ctrlKey;
|
||||
and click on</span> the link or image to display a popup menu.</li>
|
||||
and click on</span> the link or image to display a pop-up menu.</li>
|
||||
<li>Choose Copy Link Location or Copy Image Location. If an image is also a
|
||||
link, you can choose either menu item.</li>
|
||||
</ol>
|
||||
@ -276,7 +276,7 @@ Contributors:
|
||||
<ol>
|
||||
<li>Position the mouse pointer within the frame.</li>
|
||||
<li><span class="mac">Press &ctrlKey; and click on</span><span
|
||||
class="noMac">Right-click</span> the frame to display a popup menu.</li>
|
||||
class="noMac">Right-click</span> the frame to display a pop-up menu.</li>
|
||||
<li>Select <span class="menuPath">This Frame > Save Frame As</span> from
|
||||
the submenu. You will see the Save As dialog box.</li>
|
||||
<li>Choose a location for the saved page.</li>
|
||||
@ -291,7 +291,7 @@ Contributors:
|
||||
<ol>
|
||||
<li>Position the mouse pointer over the image.</li>
|
||||
<li><span class="noMac">Right-click</span><span class="mac">Press &ctrlKey;
|
||||
and click on</span> the image to display a popup menu.</li>
|
||||
and click on</span> the image to display a pop-up menu.</li>
|
||||
<li>Select <span class="menuPath">Save Image As</span>. You will see the
|
||||
Save Image dialog box.</li>
|
||||
<li>Choose a location for the saved image.</li>
|
||||
@ -304,7 +304,7 @@ Contributors:
|
||||
<ol>
|
||||
<li>Position the mouse pointer over a link to the page.</li>
|
||||
<li><span class="noMac">Right-click</span><span class="mac">Press &ctrlKey;
|
||||
and click on</span> the link to display a popup menu.</li>
|
||||
and click on</span> the link to display a pop-up menu.</li>
|
||||
<li>Select <span class="menuPath">Save Link to Disk</span>. You will see the
|
||||
Save As dialog box.</li>
|
||||
<li>Choose a location for the saved page.</li>
|
||||
@ -321,7 +321,7 @@ Contributors:
|
||||
<p><strong>Tip</strong>: To set an image as your desktop background,
|
||||
<span class="noMac">right-click</span><span class="mac">press &ctrlKey;,
|
||||
click the mouse button</span> on an image and choose <em>Set As Desktop
|
||||
Background…</em> from the popup menu.</p>
|
||||
Background…</em> from the pop-up menu.</p>
|
||||
|
||||
<h3 id="printing_a_page">Printing a Page</h3>
|
||||
|
||||
|
@ -210,8 +210,8 @@ Sanitizer.prototype = {
|
||||
{
|
||||
var pwmgr = Components.classes["@mozilla.org/login-manager;1"]
|
||||
.getService(Components.interfaces.nsILoginManager);
|
||||
var logins = pwmgr.getAllLogins({});
|
||||
return (logins.length > 0);
|
||||
var count = pwmgr.countLogins("", "", ""); // count all logins
|
||||
return (count > 0);
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -400,22 +400,42 @@ menuitem[command="cmd_fullZoomReset"] {
|
||||
|
||||
menuitem[key="goBackKb"],
|
||||
#context-back {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back?size=menu");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-ltr?size=menu");
|
||||
}
|
||||
|
||||
menuitem[key="goBackKb"][disabled],
|
||||
#context-back[disabled] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back?size=menu&state=disabled");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-ltr?size=menu&state=disabled");
|
||||
}
|
||||
|
||||
menuitem[key="goBackKb"][chromedir="rtl"],
|
||||
#context-back[chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-rtl?size=menu");
|
||||
}
|
||||
|
||||
menuitem[key="goBackKb"][disabled][chromedir="rtl"],
|
||||
#context-back[disabled][chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-rtl?size=menu&state=disabled");
|
||||
}
|
||||
|
||||
menuitem[key="goForwardKb"],
|
||||
#context-forward {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward?size=menu");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-ltr?size=menu");
|
||||
}
|
||||
|
||||
menuitem[key="goForwardKb"][disabled],
|
||||
#context-forward[disabled] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward?size=menu&state=disabled");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-ltr?size=menu&state=disabled");
|
||||
}
|
||||
|
||||
menuitem[key="goForwardKb"][chromedir="rtl"],
|
||||
#context-forward[chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-rtl?size=menu");
|
||||
}
|
||||
|
||||
menuitem[key="goForwardKb"][disabled][chromedir="rtl"],
|
||||
#context-forward[disabled][chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-rtl?size=menu&state=disabled");
|
||||
}
|
||||
|
||||
menuitem[command="Browser:Home"] {
|
||||
@ -484,18 +504,31 @@ toolbar[mode="full"] .toolbarbutton-menubutton-button {
|
||||
|
||||
/* 24px primary toolbar buttons */
|
||||
#back-button {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back?size=toolbar");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-ltr?size=toolbar");
|
||||
}
|
||||
#back-button[disabled="true"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back?size=toolbar&state=disabled");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-ltr?size=toolbar&state=disabled");
|
||||
}
|
||||
|
||||
#back-button[chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-rtl?size=toolbar");
|
||||
}
|
||||
#back-button[disabled="true"][chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-rtl?size=toolbar&state=disabled");
|
||||
}
|
||||
|
||||
/* GTK takes care of the RTL for us. Yay for libraries! */
|
||||
#forward-button {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward?size=toolbar");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-ltr?size=toolbar");
|
||||
}
|
||||
#forward-button[disabled="true"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward?size=toolbar&state=disabled");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-ltr?size=toolbar&state=disabled");
|
||||
}
|
||||
|
||||
#forward-button[chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-rtl?size=toolbar");
|
||||
}
|
||||
#forward-button[disabled="true"][chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-rtl?size=toolbar&state=disabled");
|
||||
}
|
||||
|
||||
#reload-button {
|
||||
@ -598,17 +631,31 @@ toolbar[iconsize="small"] .toolbarbutton-1[type="menu-button"] {
|
||||
}
|
||||
|
||||
toolbar[iconsize="small"] #back-button {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back?size=menu");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-ltr?size=menu");
|
||||
}
|
||||
toolbar[iconsize="small"] #back-button[disabled="true"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back?size=menu&state=disabled");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-ltr?size=menu&state=disabled");
|
||||
}
|
||||
|
||||
toolbar[iconsize="small"] #back-button[chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-rtl?size=menu");
|
||||
}
|
||||
toolbar[iconsize="small"] #back-button[disabled="true"][chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-rtl?size=menu&state=disabled");
|
||||
}
|
||||
|
||||
toolbar[iconsize="small"] #forward-button {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward?size=menu");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-ltr?size=menu");
|
||||
}
|
||||
toolbar[iconsize="small"] #forward-button[disabled="true"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward?size=menu&state=disabled");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-ltr?size=menu&state=disabled");
|
||||
}
|
||||
|
||||
toolbar[iconsize="small"] #forward-button[chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-rtl?size=menu");
|
||||
}
|
||||
toolbar[iconsize="small"] #forward-button[disabled="true"][chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-rtl?size=menu&state=disabled");
|
||||
}
|
||||
|
||||
toolbar[iconsize="small"] #stop-button {
|
||||
@ -1180,11 +1227,12 @@ tabpanels {
|
||||
|
||||
/* In-tab close button */
|
||||
.tab-close-button > .toolbarbutton-icon {
|
||||
-moz-margin-end: 0px !important;
|
||||
/* XXX Buttons have padding in widget/ that we don't want here but can't override with good CSS, so we must
|
||||
use evil CSS to give the impression of smaller content */
|
||||
margin: -3px !important;
|
||||
}
|
||||
|
||||
.tab-close-button {
|
||||
-moz-appearance: none;
|
||||
-moz-margin-end: 6px;
|
||||
padding: 0px;
|
||||
border: none;
|
||||
@ -1207,6 +1255,10 @@ tabpanels {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.tabs-closebutton > .toolbarbutton-icon {
|
||||
margin: -3px !important;
|
||||
}
|
||||
|
||||
/* All tabs menupopup */
|
||||
.alltabs-item > .menu-iconic-left > .menu-iconic-icon {
|
||||
list-style-image: url("chrome://global/skin/icons/folder-item.png");
|
||||
|
@ -7,19 +7,33 @@
|
||||
/* back button */
|
||||
|
||||
#back-button {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back?size=toolbar");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-ltr?size=toolbar");
|
||||
}
|
||||
#back-button[disabled="true"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back?size=toolbar&state=disabled");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-ltr?size=toolbar&state=disabled");
|
||||
}
|
||||
|
||||
#back-button[chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-rtl?size=toolbar");
|
||||
}
|
||||
#back-button[disabled="true"][chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-back-rtl?size=toolbar&state=disabled");
|
||||
}
|
||||
|
||||
/* forward button */
|
||||
|
||||
#forward-button {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward?size=toolbar");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-ltr?size=toolbar");
|
||||
}
|
||||
#forward-button[disabled="true"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward?size=toolbar&state=disabled");
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-ltr?size=toolbar&state=disabled");
|
||||
}
|
||||
|
||||
#forward-button[chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-rtl?size=toolbar");
|
||||
}
|
||||
#forward-button[disabled="true"][chromedir="rtl"] {
|
||||
list-style-image: url("moz-icon://stock/gtk-go-forward-rtl?size=toolbar&state=disabled");
|
||||
}
|
||||
|
||||
/* organize button */
|
||||
@ -39,13 +53,11 @@
|
||||
|
||||
/* Root View */
|
||||
#placesView {
|
||||
border-top: 1px solid ThreeDDarkShadow;
|
||||
background-color: Window;
|
||||
}
|
||||
|
||||
#splitter {
|
||||
border: 0px;
|
||||
width: 3px;
|
||||
min-width: 3px;
|
||||
}
|
||||
|
||||
/* Place List, Place Content */
|
||||
@ -54,14 +66,12 @@
|
||||
}
|
||||
|
||||
#placesList {
|
||||
-moz-appearance: none;
|
||||
margin: 0px;
|
||||
border: none;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
#placeContent {
|
||||
-moz-appearance: none;
|
||||
border: 0px;
|
||||
}
|
||||
|
||||
@ -237,28 +247,11 @@
|
||||
}
|
||||
|
||||
/**** expanders ****/
|
||||
|
||||
.expander-up,
|
||||
.expander-down {
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.expander-up {
|
||||
list-style-image: url("chrome://global/skin/arrow/arrow-up.gif");
|
||||
}
|
||||
|
||||
.expander-down {
|
||||
list-style-image: url("chrome://global/skin/arrow/arrow-dn.gif");
|
||||
}
|
||||
|
||||
.expander-down:hover:active {
|
||||
list-style-image: url("chrome://global/skin/arrow/arrow-dn-hov.gif");
|
||||
}
|
||||
|
||||
.expander-up:hover:active {
|
||||
list-style-image: url("chrome://global/skin/arrow/arrow-up-hov.gif");
|
||||
}
|
||||
|
||||
/**** menuitem stock icons ****/
|
||||
menuitem:not([type]) {
|
||||
-moz-binding: url("chrome://global/content/bindings/menu.xml#menuitem-iconic");
|
||||
|
@ -1,30 +0,0 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 9.00
|
||||
# Visual Studio 2005
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mozce_shunt", "mozce_shunt.vcproj", "{8A44014F-AAE6-4232-B8AC-584EBEB83C28}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Pocket PC 2003 (ARMV4) = Debug|Pocket PC 2003 (ARMV4)
|
||||
Debug|Smartphone 2003 (ARMV4) = Debug|Smartphone 2003 (ARMV4)
|
||||
Release|Pocket PC 2003 (ARMV4) = Release|Pocket PC 2003 (ARMV4)
|
||||
Release|Smartphone 2003 (ARMV4) = Release|Smartphone 2003 (ARMV4)
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Debug|Pocket PC 2003 (ARMV4).ActiveCfg = Debug|Pocket PC 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Debug|Pocket PC 2003 (ARMV4).Build.0 = Debug|Pocket PC 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Debug|Pocket PC 2003 (ARMV4).Deploy.0 = Debug|Pocket PC 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Debug|Smartphone 2003 (ARMV4).ActiveCfg = Debug|Smartphone 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Debug|Smartphone 2003 (ARMV4).Build.0 = Debug|Smartphone 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Debug|Smartphone 2003 (ARMV4).Deploy.0 = Debug|Smartphone 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Release|Pocket PC 2003 (ARMV4).ActiveCfg = Release|Pocket PC 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Release|Pocket PC 2003 (ARMV4).Build.0 = Release|Pocket PC 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Release|Pocket PC 2003 (ARMV4).Deploy.0 = Release|Pocket PC 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Release|Smartphone 2003 (ARMV4).ActiveCfg = Release|Smartphone 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Release|Smartphone 2003 (ARMV4).Build.0 = Release|Smartphone 2003 (ARMV4)
|
||||
{8A44014F-AAE6-4232-B8AC-584EBEB83C28}.Release|Smartphone 2003 (ARMV4).Deploy.0 = Release|Smartphone 2003 (ARMV4)
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
@ -1,459 +0,0 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
Name="mozce_shunt"
|
||||
ProjectGUID="{8A44014F-AAE6-4232-B8AC-584EBEB83C28}"
|
||||
RootNamespace="mozce_shunt"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Pocket PC 2003 (ARMV4)"
|
||||
/>
|
||||
<Platform
|
||||
Name="Smartphone 2003 (ARMV4)"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Pocket PC 2003 (ARMV4)"
|
||||
OutputDirectory="$(PlatformName)\Debug"
|
||||
IntermediateDirectory="$(PlatformName)\Debug"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ExecutionBucket="7"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../include"
|
||||
PreprocessorDefinitions="MOZCE_SHUNT_EXPORTS;_WIN32_WCE=$(CEVER);UNDER_CE=$(CEVER);WINCE;$(PLATFORMDEFINES);_DEBUG;DEBUG;_WINDOWS;_USRDLL;MOZCE_SHUNT_EXPORTS;$(ARCHFAM);$(_ARCHFAM_);_UNICODE;UNICODE"
|
||||
MinimalRebuild="true"
|
||||
ExceptionHandling="0"
|
||||
RuntimeLibrary="1"
|
||||
BufferSecurityCheck="false"
|
||||
FloatingPointModel="2"
|
||||
DisableLanguageExtensions="false"
|
||||
TreatWChar_tAsBuiltInType="false"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="_DEBUG;_UNICODE;UNICODE;_WIN32_WCE;UNDER_CE"
|
||||
Culture="1033"
|
||||
AdditionalIncludeDirectories="$(IntDir)"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=" /subsystem:windowsce,4.20 /machine:ARM /ARMPADCODE"
|
||||
OutputFile="$(OutDir)/mozce_shunt.dll"
|
||||
LinkIncremental="2"
|
||||
IgnoreDefaultLibraryNames="OLDNAMES"
|
||||
DelayLoadDLLs="$(NOINHERIT)"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(OutDir)/mozce_shunt.pdb"
|
||||
SubSystem="0"
|
||||
ImportLibrary="$(OutDir)/mozce_shunt.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCodeSignTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
<DeploymentTool
|
||||
ForceDirty="-1"
|
||||
RemoteDirectory="\bin"
|
||||
RegisterOutput="0"
|
||||
AdditionalFiles=""
|
||||
/>
|
||||
<DebuggerTool
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug|Smartphone 2003 (ARMV4)"
|
||||
OutputDirectory="$(PlatformName)\Debug"
|
||||
IntermediateDirectory="$(PlatformName)\Debug"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ExecutionBucket="7"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../include"
|
||||
PreprocessorDefinitions="MOZCE_SHUNT_EXPORTS;_WIN32_WCE=$(CEVER);UNDER_CE=$(CEVER);WINCE;$(PLATFORMDEFINES);_DEBUG;DEBUG;_WINDOWS;_USRDLL;MOZCE_SHUNT_EXPORTS;$(ARCHFAM);$(_ARCHFAM_);_UNICODE;UNICODE"
|
||||
MinimalRebuild="true"
|
||||
ExceptionHandling="0"
|
||||
RuntimeLibrary="1"
|
||||
BufferSecurityCheck="false"
|
||||
TreatWChar_tAsBuiltInType="false"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="_DEBUG;_UNICODE;UNICODE;_WIN32_WCE;UNDER_CE"
|
||||
Culture="1033"
|
||||
AdditionalIncludeDirectories="$(IntDir)"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=" /subsystem:windowsce,4.20 /machine:ARM /ARMPADCODE"
|
||||
OutputFile="$(OutDir)/mozce_shunt.dll"
|
||||
LinkIncremental="2"
|
||||
IgnoreDefaultLibraryNames="oldnames"
|
||||
DelayLoadDLLs="$(NOINHERIT)"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(OutDir)/mozce_shunt.pdb"
|
||||
SubSystem="0"
|
||||
ImportLibrary="$(OutDir)/mozce_shunt.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCodeSignTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
<DeploymentTool
|
||||
ForceDirty="-1"
|
||||
RemoteDirectory=""
|
||||
RegisterOutput="0"
|
||||
AdditionalFiles=""
|
||||
/>
|
||||
<DebuggerTool
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Pocket PC 2003 (ARMV4)"
|
||||
OutputDirectory="$(PlatformName)\Release"
|
||||
IntermediateDirectory="$(PlatformName)\Release"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ExecutionBucket="7"
|
||||
Optimization="2"
|
||||
AdditionalIncludeDirectories="../../include"
|
||||
PreprocessorDefinitions="MOZCE_SHUNT_EXPORTS;_WIN32_WCE=$(CEVER);UNDER_CE=$(CEVER);WINCE;$(PLATFORMDEFINES);NDEBUG;_WINDOWS;_USRDLL;MOZCE_SHUNT_EXPORTS;$(ARCHFAM);$(_ARCHFAM_);_UNICODE;UNICODE"
|
||||
ExceptionHandling="0"
|
||||
RuntimeLibrary="0"
|
||||
BufferSecurityCheck="false"
|
||||
DisableLanguageExtensions="false"
|
||||
TreatWChar_tAsBuiltInType="false"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="NDEBUG;_UNICODE;UNICODE;_WIN32_WCE;UNDER_CE"
|
||||
Culture="1033"
|
||||
AdditionalIncludeDirectories="$(IntDir)"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=" /subsystem:windowsce,4.20 /machine:ARM /ARMPADCODE"
|
||||
OutputFile="$(OutDir)/mozce_shunt.dll"
|
||||
LinkIncremental="1"
|
||||
IgnoreDefaultLibraryNames="OLDNAMES"
|
||||
DelayLoadDLLs="$(NOINHERIT)"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(OutDir)/mozce_shunt.pdb"
|
||||
SubSystem="0"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
ImportLibrary="$(OutDir)/mozce_shunt.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCodeSignTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
<DeploymentTool
|
||||
ForceDirty="-1"
|
||||
RemoteDirectory="\windows"
|
||||
RegisterOutput="0"
|
||||
AdditionalFiles=""
|
||||
/>
|
||||
<DebuggerTool
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Smartphone 2003 (ARMV4)"
|
||||
OutputDirectory="$(PlatformName)\Release"
|
||||
IntermediateDirectory="$(PlatformName)\Release"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ExecutionBucket="7"
|
||||
Optimization="2"
|
||||
AdditionalIncludeDirectories="../../include"
|
||||
PreprocessorDefinitions="MOZCE_SHUNT_EXPORTS;_WIN32_WCE=$(CEVER);UNDER_CE=$(CEVER);WINCE;$(PLATFORMDEFINES);NDEBUG;_WINDOWS;_USRDLL;MOZCE_SHUNT_EXPORTS;$(ARCHFAM);$(_ARCHFAM_);_UNICODE;UNICODE"
|
||||
ExceptionHandling="0"
|
||||
RuntimeLibrary="0"
|
||||
BufferSecurityCheck="false"
|
||||
TreatWChar_tAsBuiltInType="false"
|
||||
RuntimeTypeInfo="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="NDEBUG;_UNICODE;UNICODE;_WIN32_WCE;UNDER_CE"
|
||||
Culture="1033"
|
||||
AdditionalIncludeDirectories="$(IntDir)"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalOptions=" /subsystem:windowsce,4.20 /machine:ARM /ARMPADCODE"
|
||||
OutputFile="$(OutDir)/mozce_shunt.dll"
|
||||
LinkIncremental="1"
|
||||
IgnoreDefaultLibraryNames="oldnames"
|
||||
DelayLoadDLLs="$(NOINHERIT)"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(OutDir)/mozce_shunt.pdb"
|
||||
SubSystem="0"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
ImportLibrary="$(OutDir)/mozce_shunt.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCodeSignTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
<DeploymentTool
|
||||
ForceDirty="-1"
|
||||
RemoteDirectory=""
|
||||
RegisterOutput="0"
|
||||
AdditionalFiles=""
|
||||
/>
|
||||
<DebuggerTool
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
|
||||
>
|
||||
<File
|
||||
RelativePath="..\..\a2w.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\assert.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\clipboard.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\direct.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\errno.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\io.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\mbstring.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\nclog.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\process.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\signal.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\stat.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\stdio.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\stdlib.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\string.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\time.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\w2a.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\win32.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\win32A.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\win32W.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
Binary file not shown.
@ -1,29 +0,0 @@
|
||||
<html>
|
||||
<body>
|
||||
<pre>
|
||||
<h1>Build Log</h1>
|
||||
<h3>
|
||||
--------------------Configuration: shunt - Win32 (WCE ARMV4) Debug--------------------
|
||||
</h3>
|
||||
<h3>Command Lines</h3>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Results</h3>
|
||||
shunt.dll - 0 error(s), 0 warning(s)
|
||||
<h3>
|
||||
--------------------Configuration: shunt - Win32 (WCE ARMV4) Release--------------------
|
||||
</h3>
|
||||
<h3>Command Lines</h3>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Results</h3>
|
||||
shunt.dll - 0 error(s), 0 warning(s)
|
||||
</pre>
|
||||
</body>
|
||||
</html>
|
Binary file not shown.
@ -1,394 +0,0 @@
|
||||
# Microsoft eMbedded Visual Tools Project File - Name="shunt" - Package Owner=<4>
|
||||
# Microsoft eMbedded Visual Tools Generated Build File, Format Version 6.02
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (WCE ARMV4) Dynamic-Link Library" 0xa302
|
||||
|
||||
CFG=shunt - Win32 (WCE ARMV4) Release
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "shunt.vcn".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "shunt.vcn" CFG="shunt - Win32 (WCE ARMV4) Release"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "shunt - Win32 (WCE ARMV4) Release" (based on "Win32 (WCE ARMV4) Dynamic-Link Library")
|
||||
!MESSAGE "shunt - Win32 (WCE ARMV4) Debug" (based on "Win32 (WCE ARMV4) Dynamic-Link Library")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
# PROP ATL_Project 2
|
||||
CPP=clarm.exe
|
||||
MTL=midl.exe
|
||||
RSC=rc.exe
|
||||
|
||||
!IF "$(CFG)" == "shunt - Win32 (WCE ARMV4) Release"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir "ARMV4Rel"
|
||||
# PROP BASE Intermediate_Dir "ARMV4Rel"
|
||||
# PROP BASE CPU_ID "{ECBEA43D-CD7B-4852-AD55-D4227B5D624B}"
|
||||
# PROP BASE Platform_ID "{8A9A2F80-6887-11D3-842E-005004848CBA}"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir "ARMV4Rel"
|
||||
# PROP Intermediate_Dir "ARMV4Rel"
|
||||
# PROP CPU_ID "{ECBEA43D-CD7B-4852-AD55-D4227B5D624B}"
|
||||
# PROP Platform_ID "{8A9A2F80-6887-11D3-842E-005004848CBA}"
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE RSC /l 0x409 /d UNDER_CE=$(CEVersion) /d _WIN32_WCE=$(CEVersion) /d "NDEBUG" /d "UNICODE" /d "_UNICODE" /d "$(CePlatform)" /d "ARM" /d "_ARM_" /d "ARMV4" /r
|
||||
# ADD RSC /l 0x409 /d UNDER_CE=$(CEVersion) /d _WIN32_WCE=$(CEVersion) /d "NDEBUG" /d "UNICODE" /d "_UNICODE" /d "$(CePlatform)" /d "ARM" /d "_ARM_" /d "ARMV4" /r
|
||||
# ADD BASE CPP /nologo /W3 /D _WIN32_WCE=$(CEVersion) /D "$(CePlatform)" /D "ARM" /D "_ARM_" /D "ARMV4" /D UNDER_CE=$(CEVersion) /D "UNICODE" /D "_UNICODE" /D "NDEBUG" /D "SHUNT_EXPORTS" /Yu"stdafx.h" /O2 /M$(CECrtMT) /c
|
||||
# ADD CPP /nologo /W3 /Oxt /I "../include" /D "ARM" /D "_ARM_" /D "ARMV4" /D "NDEBUG" /D _WIN32_WCE=$(CEVersion) /D "$(CePlatform)" /D UNDER_CE=$(CEVersion) /D "UNICODE" /D "_UNICODE" /D "SHUNT_EXPORTS" /D "MOZCE_SHUNT_EXPORTS" /FR /M$(CECrtMT) /c
|
||||
# SUBTRACT CPP /YX /Yc /Yu
|
||||
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32
|
||||
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /o "NUL" /win32
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 commctrl.lib coredll.lib /nologo /base:"0x00100000" /stack:0x10000,0x1000 /entry:"_DllMainCRTStartup" /dll /nodefaultlib:"$(CENoDefaultLib)" /subsystem:$(CESubsystem) /align:"4096" /MACHINE:ARM
|
||||
# ADD LINK32 commctrl.lib coredll.lib ole32.lib uuid.lib /nologo /base:"0x00100000" /stack:0x10000,0x1000 /entry:"_DllMainCRTStartup" /dll /nodefaultlib:"$(CENoDefaultLib)" /subsystem:$(CESubsystem) /align:"4096" /MACHINE:ARM
|
||||
|
||||
!ELSEIF "$(CFG)" == "shunt - Win32 (WCE ARMV4) Debug"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir "ARMV4Dbg"
|
||||
# PROP BASE Intermediate_Dir "ARMV4Dbg"
|
||||
# PROP BASE CPU_ID "{ECBEA43D-CD7B-4852-AD55-D4227B5D624B}"
|
||||
# PROP BASE Platform_ID "{8A9A2F80-6887-11D3-842E-005004848CBA}"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir "ARMV4Dbg"
|
||||
# PROP Intermediate_Dir "ARMV4Dbg"
|
||||
# PROP CPU_ID "{ECBEA43D-CD7B-4852-AD55-D4227B5D624B}"
|
||||
# PROP Platform_ID "{8A9A2F80-6887-11D3-842E-005004848CBA}"
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE RSC /l 0x409 /d UNDER_CE=$(CEVersion) /d _WIN32_WCE=$(CEVersion) /d "DEBUG" /d "UNICODE" /d "_UNICODE" /d "$(CePlatform)" /d "ARM" /d "_ARM_" /d "ARMV4" /r
|
||||
# ADD RSC /l 0x409 /d UNDER_CE=$(CEVersion) /d _WIN32_WCE=$(CEVersion) /d "DEBUG" /d "UNICODE" /d "_UNICODE" /d "$(CePlatform)" /d "ARM" /d "_ARM_" /d "ARMV4" /r
|
||||
# ADD BASE CPP /nologo /W3 /Zi /Od /D "DEBUG" /D _WIN32_WCE=$(CEVersion) /D "$(CePlatform)" /D "ARM" /D "_ARM_" /D "ARMV4" /D UNDER_CE=$(CEVersion) /D "UNICODE" /D "_UNICODE" /D "SHUNT_EXPORTS" /Yu"stdafx.h" /M$(CECrtMTDebug) /c
|
||||
# ADD CPP /nologo /W3 /Zi /Od /I "../include" /D "DEBUG" /D "ARM" /D "_ARM_" /D "ARMV4" /D _WIN32_WCE=$(CEVersion) /D "$(CePlatform)" /D UNDER_CE=$(CEVersion) /D "UNICODE" /D "_UNICODE" /D "SHUNT_EXPORTS" /D "MOZCE_SHUNT_EXPORTS" /M$(CECrtMTDebug) /c
|
||||
# SUBTRACT CPP /Gf /Gy /YX /Yc /Yu
|
||||
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32
|
||||
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /o "NUL" /win32
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 commctrl.lib coredll.lib /nologo /base:"0x00100000" /stack:0x10000,0x1000 /entry:"_DllMainCRTStartup" /dll /debug /nodefaultlib:"$(CENoDefaultLib)" /subsystem:$(CESubsystem) /align:"4096" /MACHINE:ARM
|
||||
# ADD LINK32 commctrl.lib coredll.lib ole32.lib uuid.lib /nologo /base:"0x00100000" /stack:0x10000,0x1000 /entry:"_DllMainCRTStartup" /dll /debug /nodefaultlib:"$(CENoDefaultLib)" /subsystem:$(CESubsystem) /align:"4096" /MACHINE:ARM
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "shunt - Win32 (WCE ARMV4) Release"
|
||||
# Name "shunt - Win32 (WCE ARMV4) Debug"
|
||||
# Begin Group "Source Files"
|
||||
|
||||
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\a2w.cpp
|
||||
DEP_CPP_A2W_C=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\assert.cpp
|
||||
DEP_CPP_ASSER=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\clipboard.cpp
|
||||
DEP_CPP_CLIPB=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\direct.cpp
|
||||
DEP_CPP_DIREC=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\errno.cpp
|
||||
DEP_CPP_ERRNO=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\io.cpp
|
||||
DEP_CPP_IO_CP=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\mbstring.cpp
|
||||
DEP_CPP_MBSTR=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\nclog.cpp
|
||||
DEP_CPP_NCLOG=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\process.cpp
|
||||
DEP_CPP_PROCE=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
{$(INCLUDE)}"kfuncs.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\signal.cpp
|
||||
DEP_CPP_SIGNA=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\stat.cpp
|
||||
DEP_CPP_STAT_=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\include\time_conversions.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\stdio.cpp
|
||||
DEP_CPP_STDIO=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\stdlib.cpp
|
||||
DEP_CPP_STDLI=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\string.cpp
|
||||
DEP_CPP_STRIN=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\time.cpp
|
||||
DEP_CPP_TIME_=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\include\time_conversions.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\w2a.cpp
|
||||
DEP_CPP_W2A_C=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\win32.cpp
|
||||
DEP_CPP_WIN32=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
{$(INCLUDE)}"kfuncs.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\win32A.cpp
|
||||
DEP_CPP_WIN32A=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\win32W.cpp
|
||||
DEP_CPP_WIN32W=\
|
||||
"..\include\mozce_defs.h"\
|
||||
"..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Header Files"
|
||||
|
||||
# PROP Default_Filter "h;hpp;hxx;hm;inl"
|
||||
# Begin Group "sys"
|
||||
|
||||
# PROP Default_Filter ""
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\sys\socket.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\sys\stat.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\sys\timeb.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\sys\types.h
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\assert.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\crtdbg.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\ddeml.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\direct.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\dlgs.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\errno.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\fcntl.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\intshcut.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\io.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\mbstring.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\mozce_defs.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\mozce_internal.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\mozce_shunt.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\new.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\process.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\rasdlg.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\signal.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\time.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\time_conversions.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\varargs.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\winresrc.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\winsock2.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\winspool.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\winsvc.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\include\zmouse.h
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Resource Files"
|
||||
|
||||
# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
|
||||
# End Group
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ReadMe.txt
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
@ -1,29 +0,0 @@
|
||||
Microsoft eMbedded Visual Tools Workspace File, Format Version 4.00
|
||||
# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
|
||||
|
||||
###############################################################################
|
||||
|
||||
Project: "shunt"=.\shunt.vcp - Package Owner=<4>
|
||||
|
||||
Package=<5>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
Package=<4>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
###############################################################################
|
||||
|
||||
Global:
|
||||
|
||||
Package=<5>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
Package=<3>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
###############################################################################
|
||||
|
@ -1,22 +0,0 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 9.00
|
||||
# Visual Studio 2005
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "static", "static.vcproj", "{082BAB06-D10F-4C57-B123-F84DC06C246D}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I) = Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I) = Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).ActiveCfg = Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).Build.0 = Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).Deploy.0 = Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).ActiveCfg = Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).Build.0 = Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).Deploy.0 = Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
@ -1,254 +0,0 @@
|
||||
# Microsoft eMbedded Visual Tools Project File - Name="static" - Package Owner=<4>
|
||||
# Microsoft eMbedded Visual Tools Generated Build File, Format Version 6.02
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (WCE ARMV4) Static Library" 0xa304
|
||||
|
||||
CFG=static - Win32 (WCE ARMV4) Debug
|
||||
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
|
||||
!MESSAGE use the Export Makefile command and run
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "static.vcn".
|
||||
!MESSAGE
|
||||
!MESSAGE You can specify a configuration when running NMAKE
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "static.vcn" CFG="static - Win32 (WCE ARMV4) Debug"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "static - Win32 (WCE ARMV4) Release" (based on "Win32 (WCE ARMV4) Static Library")
|
||||
!MESSAGE "static - Win32 (WCE ARMV4) Debug" (based on "Win32 (WCE ARMV4) Static Library")
|
||||
!MESSAGE
|
||||
|
||||
# Begin Project
|
||||
# PROP AllowPerConfigDependencies 0
|
||||
# PROP Scc_ProjName ""
|
||||
# PROP Scc_LocalPath ""
|
||||
# PROP ATL_Project 2
|
||||
CPP=clarm.exe
|
||||
|
||||
!IF "$(CFG)" == "static - Win32 (WCE ARMV4) Release"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir "ARMV4Rel"
|
||||
# PROP BASE Intermediate_Dir "ARMV4Rel"
|
||||
# PROP BASE CPU_ID "{ECBEA43D-CD7B-4852-AD55-D4227B5D624B}"
|
||||
# PROP BASE Platform_ID "{8A9A2F80-6887-11D3-842E-005004848CBA}"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir "ARMV4Rel"
|
||||
# PROP Intermediate_Dir "ARMV4Rel"
|
||||
# PROP CPU_ID "{ECBEA43D-CD7B-4852-AD55-D4227B5D624B}"
|
||||
# PROP Platform_ID "{8A9A2F80-6887-11D3-842E-005004848CBA}"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /D _WIN32_WCE=$(CEVersion) /D "$(CePlatform)" /D "NDEBUG" /D "ARM" /D "_ARM_" /D "ARMV4" /D UNDER_CE=$(CEVersion) /D "UNICODE" /D "_UNICODE" /D "_LIB" /YX /O2 /M$(CECrtMT) /c
|
||||
# ADD CPP /nologo /W3 /Gy /I "..\..\\" /I "..\..\include" /D "NDEBUG" /D _WIN32_WCE=$(CEVersion) /D "$(CePlatform)" /D "ARM" /D "_ARM_" /D "ARMV4" /D UNDER_CE=$(CEVersion) /D "UNICODE" /D "_UNICODE" /D "_LIB" /D "MOZCE_SHUNT_EXPORTS" /O2 /M$(CECrtMT) /c
|
||||
# SUBTRACT CPP /YX
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo /out:"ARMV4Rel\shunt.lib"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
|
||||
!ELSEIF "$(CFG)" == "static - Win32 (WCE ARMV4) Debug"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir "ARMV4Dbg"
|
||||
# PROP BASE Intermediate_Dir "ARMV4Dbg"
|
||||
# PROP BASE CPU_ID "{ECBEA43D-CD7B-4852-AD55-D4227B5D624B}"
|
||||
# PROP BASE Platform_ID "{8A9A2F80-6887-11D3-842E-005004848CBA}"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir "ARMV4Dbg"
|
||||
# PROP Intermediate_Dir "ARMV4Dbg"
|
||||
# PROP CPU_ID "{ECBEA43D-CD7B-4852-AD55-D4227B5D624B}"
|
||||
# PROP Platform_ID "{8A9A2F80-6887-11D3-842E-005004848CBA}"
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /Zi /Od /D "DEBUG" /D _WIN32_WCE=$(CEVersion) /D "$(CePlatform)" /D "ARM" /D "_ARM_" /D "ARMV4" /D UNDER_CE=$(CEVersion) /D "UNICODE" /D "_UNICODE" /D "_LIB" /YX /M$(CECrtMTDebug) /c
|
||||
# ADD CPP /nologo /W3 /Zi /Od /Gy /I "..\..\\" /I "..\..\include" /D "DEBUG" /D _WIN32_WCE=$(CEVersion) /D "$(CePlatform)" /D "ARM" /D "_ARM_" /D "ARMV4" /D UNDER_CE=$(CEVersion) /D "UNICODE" /D "_UNICODE" /D "_LIB" /D "MOZCE_SHUNT_EXPORTS" /M$(CECrtMTDebug) /c
|
||||
# SUBTRACT CPP /YX
|
||||
LIB32=link.exe -lib
|
||||
# ADD BASE LIB32 /nologo
|
||||
# ADD LIB32 /nologo /out:"ARMV4Dbg\shunt.lib"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
|
||||
!ENDIF
|
||||
|
||||
# Begin Target
|
||||
|
||||
# Name "static - Win32 (WCE ARMV4) Release"
|
||||
# Name "static - Win32 (WCE ARMV4) Debug"
|
||||
# Begin Group "Source Files"
|
||||
|
||||
# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\a2w.cpp
|
||||
DEP_CPP_A2W_C=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\assert.cpp
|
||||
DEP_CPP_ASSER=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\clipboard.cpp
|
||||
DEP_CPP_CLIPB=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\direct.cpp
|
||||
DEP_CPP_DIREC=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\errno.cpp
|
||||
DEP_CPP_ERRNO=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\io.cpp
|
||||
DEP_CPP_IO_CP=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\mbstring.cpp
|
||||
DEP_CPP_MBSTR=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\nclog.cpp
|
||||
DEP_CPP_NCLOG=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\process.cpp
|
||||
DEP_CPP_PROCE=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
{$(INCLUDE)}"kfuncs.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\signal.cpp
|
||||
DEP_CPP_SIGNA=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\stat.cpp
|
||||
DEP_CPP_STAT_=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\include\time_conversions.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\stdio.cpp
|
||||
DEP_CPP_STDIO=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\stdlib.cpp
|
||||
DEP_CPP_STDLI=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\string.cpp
|
||||
DEP_CPP_STRIN=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\time.cpp
|
||||
DEP_CPP_TIME_=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\include\time_conversions.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\w2a.cpp
|
||||
DEP_CPP_W2A_C=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\win32.cpp
|
||||
DEP_CPP_WIN32=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
{$(INCLUDE)}"kfuncs.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\win32A.cpp
|
||||
DEP_CPP_WIN32A=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=..\..\win32W.cpp
|
||||
DEP_CPP_WIN32W=\
|
||||
"..\..\include\mozce_defs.h"\
|
||||
"..\..\mozce_internal.h"\
|
||||
|
||||
# End Source File
|
||||
# End Group
|
||||
# Begin Group "Header Files"
|
||||
|
||||
# PROP Default_Filter "h;hpp;hxx;hm;inl"
|
||||
# End Group
|
||||
# End Target
|
||||
# End Project
|
@ -1,277 +0,0 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
Name="static"
|
||||
ProjectGUID="{082BAB06-D10F-4C57-B123-F84DC06C246D}"
|
||||
RootNamespace="static"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Windows Mobile 5.0 Pocket PC SDK (ARMV4I)"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)"
|
||||
OutputDirectory="$(PlatformName)\Debug"
|
||||
IntermediateDirectory="$(PlatformName)\Debug"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ExecutionBucket="7"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="..\..\include"
|
||||
PreprocessorDefinitions="_WIN32_WCE=$(CEVER);UNDER_CE=$(CEVER);WINCE;$(PLATFORMDEFINES);_DEBUG;DEBUG;_LIB;$(ARCHFAM);$(_ARCHFAM_);MOZCE_STATIC_BUILD"
|
||||
MinimalRebuild="true"
|
||||
ExceptionHandling="0"
|
||||
RuntimeLibrary="1"
|
||||
EnableFunctionLevelLinking="true"
|
||||
TreatWChar_tAsBuiltInType="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="_DEBUG;_UNICODE;UNICODE;_WIN32_WCE;UNDER_CE"
|
||||
Culture="1033"
|
||||
AdditionalIncludeDirectories="$(IntDir)"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalOptions=" /subsystem:windowsce,5.01 /machine:THUMB"
|
||||
OutputFile="$(InputDir)/shunt_dbg.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCodeSignTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
<DeploymentTool
|
||||
ForceDirty="-1"
|
||||
RemoteDirectory=""
|
||||
RegisterOutput="0"
|
||||
AdditionalFiles=""
|
||||
/>
|
||||
<DebuggerTool
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)"
|
||||
OutputDirectory="$(PlatformName)\Release"
|
||||
IntermediateDirectory="$(PlatformName)\Release"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
ExecutionBucket="7"
|
||||
Optimization="2"
|
||||
AdditionalIncludeDirectories="..\..\include"
|
||||
PreprocessorDefinitions="_WIN32_WCE=$(CEVER);UNDER_CE=$(CEVER);WINCE;$(PLATFORMDEFINES);NDEBUG;_LIB;$(ARCHFAM);$(_ARCHFAM_);"
|
||||
ExceptionHandling="0"
|
||||
RuntimeLibrary="0"
|
||||
TreatWChar_tAsBuiltInType="false"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
DebugInformationFormat="3"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
PreprocessorDefinitions="NDEBUG;_UNICODE;UNICODE;_WIN32_WCE;UNDER_CE"
|
||||
Culture="1033"
|
||||
AdditionalIncludeDirectories="$(IntDir)"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalOptions=" /subsystem:windowsce,5.01 /machine:THUMB"
|
||||
OutputFile="$(InputDir)/shunt.lib"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCodeSignTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
<DeploymentTool
|
||||
ForceDirty="-1"
|
||||
RemoteDirectory=""
|
||||
RegisterOutput="0"
|
||||
AdditionalFiles=""
|
||||
/>
|
||||
<DebuggerTool
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
|
||||
>
|
||||
<File
|
||||
RelativePath="..\..\a2w.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\assert.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\clipboard.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\direct.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\errno.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\io.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\mbstring.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\nclog.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\process.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\signal.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\stat.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\stdio.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\stdlib.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\string.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\time.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\w2a.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\win32.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\win32A.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\win32W.cpp"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl;inc;xsd"
|
||||
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
|
||||
>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
|
||||
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
|
||||
>
|
||||
</Filter>
|
||||
<File
|
||||
RelativePath=".\ReadMe.txt"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
@ -1,29 +0,0 @@
|
||||
Microsoft eMbedded Visual Tools Workspace File, Format Version 4.00
|
||||
# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
|
||||
|
||||
###############################################################################
|
||||
|
||||
Project: "static"=.\static.vcp - Package Owner=<4>
|
||||
|
||||
Package=<5>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
Package=<4>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
###############################################################################
|
||||
|
||||
Global:
|
||||
|
||||
Package=<5>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
Package=<3>
|
||||
{{{
|
||||
}}}
|
||||
|
||||
###############################################################################
|
||||
|
@ -1,46 +1,30 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 9.00
|
||||
# Visual Studio 2005
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mozce_shunt_static", "mozce_shunt_static.vcproj", "{082BAB06-D10F-4C57-B123-F84DC06C246D}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Pocket PC 2003 (ARMV4) = Debug|Pocket PC 2003 (ARMV4)
|
||||
Debug|Smartphone 2003 (ARMV4) = Debug|Smartphone 2003 (ARMV4)
|
||||
Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I) = Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
Debug|Windows Mobile 5.0 Smartphone SDK (ARMV4I) = Debug|Windows Mobile 5.0 Smartphone SDK (ARMV4I)
|
||||
Release|Pocket PC 2003 (ARMV4) = Release|Pocket PC 2003 (ARMV4)
|
||||
Release|Smartphone 2003 (ARMV4) = Release|Smartphone 2003 (ARMV4)
|
||||
Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I) = Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
Release|Windows Mobile 5.0 Smartphone SDK (ARMV4I) = Release|Windows Mobile 5.0 Smartphone SDK (ARMV4I)
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Pocket PC 2003 (ARMV4).ActiveCfg = Debug|Pocket PC 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Pocket PC 2003 (ARMV4).Build.0 = Debug|Pocket PC 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Pocket PC 2003 (ARMV4).Deploy.0 = Debug|Pocket PC 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Smartphone 2003 (ARMV4).ActiveCfg = Debug|Smartphone 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Smartphone 2003 (ARMV4).Build.0 = Debug|Smartphone 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Smartphone 2003 (ARMV4).Deploy.0 = Debug|Smartphone 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).ActiveCfg = Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).Build.0 = Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).Deploy.0 = Debug|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Smartphone SDK (ARMV4I).ActiveCfg = Debug|Windows Mobile 5.0 Smartphone SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Smartphone SDK (ARMV4I).Build.0 = Debug|Windows Mobile 5.0 Smartphone SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 5.0 Smartphone SDK (ARMV4I).Deploy.0 = Debug|Windows Mobile 5.0 Smartphone SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Pocket PC 2003 (ARMV4).ActiveCfg = Release|Pocket PC 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Pocket PC 2003 (ARMV4).Build.0 = Release|Pocket PC 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Pocket PC 2003 (ARMV4).Deploy.0 = Release|Pocket PC 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Smartphone 2003 (ARMV4).ActiveCfg = Release|Smartphone 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Smartphone 2003 (ARMV4).Build.0 = Release|Smartphone 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Smartphone 2003 (ARMV4).Deploy.0 = Release|Smartphone 2003 (ARMV4)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).ActiveCfg = Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).Build.0 = Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I).Deploy.0 = Release|Windows Mobile 5.0 Pocket PC SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Smartphone SDK (ARMV4I).ActiveCfg = Release|Windows Mobile 5.0 Smartphone SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Smartphone SDK (ARMV4I).Build.0 = Release|Windows Mobile 5.0 Smartphone SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 5.0 Smartphone SDK (ARMV4I).Deploy.0 = Release|Windows Mobile 5.0 Smartphone SDK (ARMV4I)
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 9.00
|
||||
# Visual Studio 2005
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mozce_shunt_static", "mozce_shunt_static.vcproj", "{082BAB06-D10F-4C57-B123-F84DC06C246D}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Windows Mobile 6 Professional SDK (ARMV4I) = Debug|Windows Mobile 6 Professional SDK (ARMV4I)
|
||||
Debug|Windows Mobile 6 Standard SDK (ARMV4I) = Debug|Windows Mobile 6 Standard SDK (ARMV4I)
|
||||
Release|Windows Mobile 6 Professional SDK (ARMV4I) = Release|Windows Mobile 6 Professional SDK (ARMV4I)
|
||||
Release|Windows Mobile 6 Standard SDK (ARMV4I) = Release|Windows Mobile 6 Standard SDK (ARMV4I)
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 6 Professional SDK (ARMV4I).ActiveCfg = Debug|Windows Mobile 6 Professional SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 6 Professional SDK (ARMV4I).Build.0 = Debug|Windows Mobile 6 Professional SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 6 Professional SDK (ARMV4I).Deploy.0 = Debug|Windows Mobile 6 Professional SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 6 Standard SDK (ARMV4I).ActiveCfg = Debug|Windows Mobile 6 Standard SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 6 Standard SDK (ARMV4I).Build.0 = Debug|Windows Mobile 6 Standard SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Debug|Windows Mobile 6 Standard SDK (ARMV4I).Deploy.0 = Debug|Windows Mobile 6 Standard SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 6 Professional SDK (ARMV4I).ActiveCfg = Release|Windows Mobile 6 Professional SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 6 Professional SDK (ARMV4I).Build.0 = Release|Windows Mobile 6 Professional SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 6 Professional SDK (ARMV4I).Deploy.0 = Release|Windows Mobile 6 Professional SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 6 Standard SDK (ARMV4I).ActiveCfg = Release|Windows Mobile 6 Standard SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 6 Standard SDK (ARMV4I).Build.0 = Release|Windows Mobile 6 Standard SDK (ARMV4I)
|
||||
{082BAB06-D10F-4C57-B123-F84DC06C246D}.Release|Windows Mobile 6 Standard SDK (ARMV4I).Deploy.0 = Release|Windows Mobile 6 Standard SDK (ARMV4I)
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,310 +1,311 @@
|
||||
/* ***** 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 WinCE Shunt
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Douglas F. Turner II <dougt@meer.net>
|
||||
* Portions created by the Initial Developer are Copyright (C) 2005
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
*
|
||||
* 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 "mozce_internal.h"
|
||||
|
||||
extern "C" {
|
||||
#if 0
|
||||
}
|
||||
#endif
|
||||
|
||||
static IDataObject* gDataObject = NULL;
|
||||
static HWND gClipboardWND = NULL; /* we may need to free this */
|
||||
|
||||
void oleSetup()
|
||||
{
|
||||
if (gClipboardWND)
|
||||
return;
|
||||
|
||||
WNDCLASS wndclass;
|
||||
ZeroMemory( &wndclass, sizeof(WNDCLASS));
|
||||
|
||||
|
||||
wndclass.style = CS_GLOBALCLASS;
|
||||
wndclass.lpfnWndProc = DefWindowProc;
|
||||
wndclass.lpszClassName = L"OLE_CLIPBOARD";
|
||||
|
||||
RegisterClass(&wndclass);
|
||||
|
||||
gClipboardWND = CreateWindow(L"OLE_Clipboard",
|
||||
0,
|
||||
0,
|
||||
CW_USEDEFAULT, CW_USEDEFAULT,
|
||||
CW_USEDEFAULT, CW_USEDEFAULT,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0);
|
||||
}
|
||||
|
||||
class ClipDataObj : public IDataObject
|
||||
{
|
||||
public:
|
||||
ClipDataObj()
|
||||
{
|
||||
mRefCnt = 0;
|
||||
}
|
||||
|
||||
~ClipDataObj()
|
||||
{
|
||||
}
|
||||
|
||||
STDMETHODIMP_(ULONG) AddRef()
|
||||
{
|
||||
mRefCnt++;
|
||||
return mRefCnt;
|
||||
}
|
||||
|
||||
STDMETHODIMP QueryInterface(REFIID iid, void **ppvObject)
|
||||
{
|
||||
// check to see what interface has been requested
|
||||
if(iid == IID_IDataObject || iid == IID_IUnknown)
|
||||
{
|
||||
AddRef();
|
||||
*ppvObject = this;
|
||||
return S_OK;
|
||||
}
|
||||
else
|
||||
{
|
||||
*ppvObject = 0;
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
}
|
||||
|
||||
STDMETHODIMP_(ULONG) Release()
|
||||
{
|
||||
mRefCnt--;
|
||||
if (mRefCnt == 0)
|
||||
{
|
||||
delete this;
|
||||
return 0;
|
||||
}
|
||||
|
||||
return mRefCnt;
|
||||
}
|
||||
|
||||
STDMETHODIMP GetData (FORMATETC *pFormatEtc, STGMEDIUM *pMedium)
|
||||
{
|
||||
|
||||
oleSetup();
|
||||
|
||||
BOOL b = OpenClipboard(gClipboardWND);
|
||||
|
||||
if (!b)
|
||||
return E_FAIL;
|
||||
|
||||
HANDLE hData = GetClipboardData(pFormatEtc->cfFormat);
|
||||
|
||||
LPVOID src = GlobalLock(hData);
|
||||
if(src) {
|
||||
ULONG size = GlobalSize(hData);
|
||||
HANDLE hDest = GlobalAlloc(GHND, size);
|
||||
LPVOID dest = GlobalLock(hDest);
|
||||
memcpy(dest, src, size);
|
||||
|
||||
GlobalUnlock(hDest);
|
||||
GlobalUnlock(hData);
|
||||
|
||||
hData = hDest;
|
||||
}
|
||||
|
||||
pMedium->tymed = (hData == 0) ? TYMED_NULL : TYMED_HGLOBAL;
|
||||
pMedium->hGlobal = (HGLOBAL)hData;
|
||||
pMedium->pUnkForRelease = NULL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
STDMETHODIMP GetDataHere (LPFORMATETC pFE, LPSTGMEDIUM pSTM)
|
||||
{
|
||||
return DATA_E_FORMATETC;
|
||||
}
|
||||
|
||||
STDMETHODIMP QueryGetData (LPFORMATETC pFE)
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
STDMETHODIMP GetCanonicalFormatEtc (LPFORMATETC pFE, LPFORMATETC pCanonFE)
|
||||
{
|
||||
pFE->ptd = NULL;
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
STDMETHODIMP SetData (LPFORMATETC pFE, LPSTGMEDIUM pSTM, BOOL release)
|
||||
{
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
STDMETHODIMP EnumFormatEtc (DWORD dwDirection, LPENUMFORMATETC* ppEnum)
|
||||
{
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
STDMETHODIMP DAdvise (LPFORMATETC pFE, DWORD flags, LPADVISESINK pAdvise, DWORD* pConn)
|
||||
{
|
||||
return OLE_E_ADVISENOTSUPPORTED;
|
||||
}
|
||||
|
||||
STDMETHODIMP DUnadvise (DWORD pConn)
|
||||
{
|
||||
return OLE_E_ADVISENOTSUPPORTED;
|
||||
}
|
||||
|
||||
STDMETHODIMP EnumDAdvise (LPENUMSTATDATA *ppEnum)
|
||||
{
|
||||
return OLE_E_ADVISENOTSUPPORTED;
|
||||
}
|
||||
private:
|
||||
LONG mRefCnt;
|
||||
};
|
||||
|
||||
|
||||
|
||||
MOZCE_SHUNT_API HRESULT mozce_OleSetClipboard(IDataObject * pDataObj)
|
||||
{
|
||||
MOZCE_PRECHECK
|
||||
|
||||
oleSetup();
|
||||
|
||||
if (gDataObject)
|
||||
gDataObject->Release();
|
||||
|
||||
gDataObject = pDataObj;
|
||||
|
||||
if (pDataObj)
|
||||
{
|
||||
BOOL b = OpenClipboard(gClipboardWND);
|
||||
|
||||
if (!b)
|
||||
return E_FAIL;
|
||||
|
||||
EmptyClipboard();
|
||||
|
||||
pDataObj->AddRef();
|
||||
|
||||
IEnumFORMATETC* enumerator = NULL;
|
||||
pDataObj->EnumFormatEtc(DATADIR_GET, &enumerator);
|
||||
if (!enumerator)
|
||||
return S_OK;
|
||||
|
||||
FORMATETC etc;
|
||||
|
||||
while (S_OK == enumerator->Next(1, &etc, NULL))
|
||||
{
|
||||
if ( etc.tymed == TYMED_HGLOBAL )
|
||||
{
|
||||
|
||||
STGMEDIUM medium;
|
||||
pDataObj->GetData(&etc, &medium);
|
||||
SetClipboardData( etc.cfFormat, medium.hGlobal);
|
||||
}
|
||||
}
|
||||
|
||||
enumerator->Release();
|
||||
|
||||
CloseClipboard();
|
||||
|
||||
}
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
MOZCE_SHUNT_API HRESULT mozce_OleGetClipboard(IDataObject ** pDataObj)
|
||||
{
|
||||
MOZCE_PRECHECK
|
||||
oleSetup();
|
||||
|
||||
if (pDataObj)
|
||||
*pDataObj = gDataObject;
|
||||
|
||||
if (!*pDataObj)
|
||||
{
|
||||
*pDataObj = new ClipDataObj();
|
||||
if (!*pDataObj)
|
||||
return E_FAIL;
|
||||
|
||||
gDataObject = *pDataObj;
|
||||
}
|
||||
|
||||
(*pDataObj)->AddRef();
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
MOZCE_SHUNT_API HRESULT mozce_OleFlushClipboard()
|
||||
{
|
||||
MOZCE_PRECHECK
|
||||
oleSetup();
|
||||
|
||||
mozce_OleSetClipboard(NULL);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
MOZCE_SHUNT_API BOOL mozce_IsClipboardFormatAvailable(UINT format)
|
||||
{
|
||||
if (gClipboardWND)
|
||||
{
|
||||
BOOL b = OpenClipboard(gClipboardWND);
|
||||
if (!b)
|
||||
return E_FAIL;
|
||||
|
||||
IEnumFORMATETC* enumerator = NULL;
|
||||
gDataObject->EnumFormatEtc(DATADIR_GET, &enumerator);
|
||||
if (!enumerator)
|
||||
return S_OK;
|
||||
|
||||
FORMATETC etc;
|
||||
|
||||
while (S_OK == enumerator->Next(1, &etc, NULL))
|
||||
{
|
||||
if ( etc.cfFormat == format)
|
||||
{
|
||||
enumerator->Release();
|
||||
CloseClipboard();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
enumerator->Release();
|
||||
CloseClipboard();
|
||||
}
|
||||
|
||||
return IsClipboardFormatAvailable(format);
|
||||
}
|
||||
|
||||
#if 0
|
||||
{
|
||||
#endif
|
||||
} /* extern "C" */
|
||||
/* ***** 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 WinCE Shunt
|
||||
*
|
||||
* The Initial Developer of the Original Code is
|
||||
* Douglas F. Turner II <dougt@meer.net>
|
||||
* Portions created by the Initial Developer are Copyright (C) 2005
|
||||
* the Initial Developer. All Rights Reserved.
|
||||
*
|
||||
* Contributor(s):
|
||||
*
|
||||
* 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 "mozce_internal.h"
|
||||
|
||||
extern "C" {
|
||||
#if 0
|
||||
}
|
||||
#endif
|
||||
|
||||
static IDataObject* gDataObject = NULL;
|
||||
static HWND gClipboardWND = NULL; /* we may need to free this */
|
||||
|
||||
void oleSetup()
|
||||
{
|
||||
if (gClipboardWND)
|
||||
return;
|
||||
|
||||
WNDCLASS wndclass;
|
||||
ZeroMemory( &wndclass, sizeof(WNDCLASS));
|
||||
|
||||
|
||||
wndclass.style = CS_GLOBALCLASS;
|
||||
wndclass.lpfnWndProc = DefWindowProc;
|
||||
wndclass.lpszClassName = L"OLE_CLIPBOARD";
|
||||
|
||||
RegisterClass(&wndclass);
|
||||
|
||||
gClipboardWND = CreateWindow(L"OLE_Clipboard",
|
||||
0,
|
||||
0,
|
||||
CW_USEDEFAULT, CW_USEDEFAULT,
|
||||
CW_USEDEFAULT, CW_USEDEFAULT,
|
||||
0,
|
||||
0,
|
||||
0,
|
||||
0);
|
||||
}
|
||||
|
||||
class ClipDataObj : public IDataObject
|
||||
{
|
||||
public:
|
||||
ClipDataObj()
|
||||
{
|
||||
mRefCnt = 0;
|
||||
}
|
||||
|
||||
~ClipDataObj()
|
||||
{
|
||||
}
|
||||
|
||||
STDMETHODIMP_(ULONG) AddRef()
|
||||
{
|
||||
mRefCnt++;
|
||||
return mRefCnt;
|
||||
}
|
||||
|
||||
STDMETHODIMP QueryInterface(REFIID iid, void **ppvObject)
|
||||
{
|
||||
// check to see what interface has been requested
|
||||
if(iid == IID_IDataObject || iid == IID_IUnknown)
|
||||
{
|
||||
AddRef();
|
||||
*ppvObject = this;
|
||||
return S_OK;
|
||||
}
|
||||
else
|
||||
{
|
||||
*ppvObject = 0;
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
}
|
||||
|
||||
STDMETHODIMP_(ULONG) Release()
|
||||
{
|
||||
mRefCnt--;
|
||||
if (mRefCnt == 0)
|
||||
{
|
||||
delete this;
|
||||
return 0;
|
||||
}
|
||||
|
||||
return mRefCnt;
|
||||
}
|
||||
|
||||
STDMETHODIMP GetData (FORMATETC *pFormatEtc, STGMEDIUM *pMedium)
|
||||
{
|
||||
|
||||
oleSetup();
|
||||
|
||||
BOOL b = OpenClipboard(gClipboardWND);
|
||||
|
||||
if (!b)
|
||||
return E_FAIL;
|
||||
|
||||
HANDLE hData = GetClipboardData(pFormatEtc->cfFormat);
|
||||
|
||||
LPVOID src = GlobalLock(hData);
|
||||
if(src) {
|
||||
ULONG size = GlobalSize(hData);
|
||||
HANDLE hDest = GlobalAlloc(GHND, size);
|
||||
LPVOID dest = GlobalLock(hDest);
|
||||
memcpy(dest, src, size);
|
||||
|
||||
GlobalUnlock(hDest);
|
||||
GlobalUnlock(hData);
|
||||
|
||||
hData = hDest;
|
||||
}
|
||||
|
||||
pMedium->tymed = (hData == 0) ? TYMED_NULL : TYMED_HGLOBAL;
|
||||
pMedium->hGlobal = (HGLOBAL)hData;
|
||||
pMedium->pUnkForRelease = NULL;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
STDMETHODIMP GetDataHere (LPFORMATETC pFE, LPSTGMEDIUM pSTM)
|
||||
{
|
||||
return DATA_E_FORMATETC;
|
||||
}
|
||||
|
||||
STDMETHODIMP QueryGetData (LPFORMATETC pFE)
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
STDMETHODIMP GetCanonicalFormatEtc (LPFORMATETC pFE, LPFORMATETC pCanonFE)
|
||||
{
|
||||
pFE->ptd = NULL;
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
STDMETHODIMP SetData (LPFORMATETC pFE, LPSTGMEDIUM pSTM, BOOL release)
|
||||
{
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
STDMETHODIMP EnumFormatEtc (DWORD dwDirection, LPENUMFORMATETC* ppEnum)
|
||||
{
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
STDMETHODIMP DAdvise (LPFORMATETC pFE, DWORD flags, LPADVISESINK pAdvise, DWORD* pConn)
|
||||
{
|
||||
return OLE_E_ADVISENOTSUPPORTED;
|
||||
}
|
||||
|
||||
STDMETHODIMP DUnadvise (DWORD pConn)
|
||||
{
|
||||
return OLE_E_ADVISENOTSUPPORTED;
|
||||
}
|
||||
|
||||
STDMETHODIMP EnumDAdvise (LPENUMSTATDATA *ppEnum)
|
||||
{
|
||||
return OLE_E_ADVISENOTSUPPORTED;
|
||||
}
|
||||
private:
|
||||
LONG mRefCnt;
|
||||
};
|
||||
|
||||
|
||||
|
||||
MOZCE_SHUNT_API HRESULT OleSetClipboard(IDataObject * pDataObj)
|
||||
{
|
||||
MOZCE_PRECHECK
|
||||
|
||||
oleSetup();
|
||||
|
||||
if (gDataObject)
|
||||
gDataObject->Release();
|
||||
|
||||
gDataObject = pDataObj;
|
||||
|
||||
if (pDataObj)
|
||||
{
|
||||
BOOL b = OpenClipboard(gClipboardWND);
|
||||
|
||||
if (!b)
|
||||
return E_FAIL;
|
||||
|
||||
EmptyClipboard();
|
||||
|
||||
pDataObj->AddRef();
|
||||
|
||||
IEnumFORMATETC* enumerator = NULL;
|
||||
pDataObj->EnumFormatEtc(DATADIR_GET, &enumerator);
|
||||
if (!enumerator)
|
||||
return S_OK;
|
||||
|
||||
FORMATETC etc;
|
||||
|
||||
while (S_OK == enumerator->Next(1, &etc, NULL))
|
||||
{
|
||||
if ( etc.tymed == TYMED_HGLOBAL )
|
||||
{
|
||||
|
||||
STGMEDIUM medium;
|
||||
pDataObj->GetData(&etc, &medium);
|
||||
SetClipboardData( etc.cfFormat, medium.hGlobal);
|
||||
}
|
||||
}
|
||||
|
||||
enumerator->Release();
|
||||
|
||||
CloseClipboard();
|
||||
|
||||
}
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
// dougt?? do we need this clipboard function
|
||||
MOZCE_SHUNT_API HRESULT OleGetClipboard(IDataObject ** pDataObj)
|
||||
{
|
||||
MOZCE_PRECHECK
|
||||
oleSetup();
|
||||
|
||||
if (pDataObj)
|
||||
*pDataObj = gDataObject;
|
||||
|
||||
if (!*pDataObj)
|
||||
{
|
||||
*pDataObj = new ClipDataObj();
|
||||
if (!*pDataObj)
|
||||
return E_FAIL;
|
||||
|
||||
gDataObject = *pDataObj;
|
||||
}
|
||||
|
||||
(*pDataObj)->AddRef();
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
MOZCE_SHUNT_API HRESULT OleFlushClipboard()
|
||||
{
|
||||
MOZCE_PRECHECK
|
||||
oleSetup();
|
||||
|
||||
OleSetClipboard(NULL);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
||||
MOZCE_SHUNT_API BOOL IsClipboardFormatAvailable(UINT format)
|
||||
{
|
||||
if (gClipboardWND)
|
||||
{
|
||||
BOOL b = OpenClipboard(gClipboardWND);
|
||||
if (!b)
|
||||
return E_FAIL;
|
||||
|
||||
IEnumFORMATETC* enumerator = NULL;
|
||||
gDataObject->EnumFormatEtc(DATADIR_GET, &enumerator);
|
||||
if (!enumerator)
|
||||
return S_OK;
|
||||
|
||||
FORMATETC etc;
|
||||
|
||||
while (S_OK == enumerator->Next(1, &etc, NULL))
|
||||
{
|
||||
if ( etc.cfFormat == format)
|
||||
{
|
||||
enumerator->Release();
|
||||
CloseClipboard();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
enumerator->Release();
|
||||
CloseClipboard();
|
||||
}
|
||||
|
||||
return IsClipboardFormatAvailable(format);
|
||||
}
|
||||
|
||||
#if 0
|
||||
{
|
||||
#endif
|
||||
} /* extern "C" */
|
||||
|
@ -47,12 +47,12 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
|
||||
MOZCE_SHUNT_API int mozce_mkdir(const char* inDirname)
|
||||
MOZCE_SHUNT_API int mkdir(const char* inDirname)
|
||||
{
|
||||
MOZCE_PRECHECK
|
||||
|
||||
#ifdef DEBUG
|
||||
mozce_printf("mozce_mkdir called\n");
|
||||
mozce_printf("mkdir called\n");
|
||||
#endif
|
||||
|
||||
int retval = -1;
|
||||
@ -74,12 +74,12 @@ MOZCE_SHUNT_API int mozce_mkdir(const char* inDirname)
|
||||
}
|
||||
|
||||
|
||||
MOZCE_SHUNT_API int mozce_rmdir(const char* inDirname)
|
||||
MOZCE_SHUNT_API int rmdir(const char* inDirname)
|
||||
{
|
||||
MOZCE_PRECHECK
|
||||
|
||||
#ifdef DEBUG
|
||||
mozce_printf("mozce_rmdir called (%s)\n", inDirname);
|
||||
mozce_printf("rmdir called (%s)\n", inDirname);
|
||||
#endif
|
||||
|
||||
int retval = -1;
|
||||
|
@ -45,7 +45,7 @@ extern "C" {
|
||||
}
|
||||
#endif
|
||||
|
||||
MOZCE_SHUNT_API int mozce_errno = 0;
|
||||
MOZCE_SHUNT_API int errno = 0;
|
||||
|
||||
#if 0
|
||||
{
|
||||
|
@ -1 +0,0 @@
|
||||
#include "mozce_shunt.h"
|
@ -1 +0,0 @@
|
||||
#include "mozce_shunt.h"
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user