This commit is contained in:
hyatt%netscape.com 2000-02-08 01:02:47 +00:00
Родитель d6a1917e8a
Коммит f280862dfb
7 изменённых файлов: 74 добавлений и 89 удалений

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

@ -50,7 +50,6 @@
<box class="tabpanel" id="system" flex="100%" align="vertical">
<box><html:div>&div.cookiesonsystem.label;</html:div></box>
<spring style="height: 10px;"/>
<html:div style="width: 380px;">
<tree id="cookietree" class="inset" style="height: 150px; width: 380px;" align="vertical"
onselect="ViewCookieSelected(event);"
onclick="ViewCookieSelected(event)"
@ -65,7 +64,6 @@
</treehead>
<treechildren id="cookielist"/>
</tree>
</html:div>
<spring style="height: 5px;"/>
<html:fieldset style="border: 2px groove #CCCCDD;">
<html:legend>&treehead.infoselected.label;</html:legend>

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

@ -78,11 +78,14 @@ nsMenuBarListener::KeyUp(nsIDOMEvent* aKeyEvent)
nsCOMPtr<nsIDOMKeyEvent> keyEvent = do_QueryInterface(aKeyEvent);
PRUint32 theChar;
keyEvent->GetKeyCode(&theChar);
#ifndef XP_UNIX
if (theChar == NS_VK_ALT && mAltKeyDown) {
// The ALT key was down and is now up.
mAltKeyDown = PR_FALSE;
mMenuBarFrame->ToggleMenuActiveState();
}
#endif
PRBool active = mMenuBarFrame->IsActive();
if (active) {
@ -130,7 +133,6 @@ nsMenuBarListener::KeyDown(nsIDOMEvent* aKeyEvent)
// Close one level.
if (active) {
mMenuBarFrame->Escape();
//if(!mMenuBarFrame->IsActive())
mKeyboardNavigationActive = PR_FALSE;
}
}
@ -140,6 +142,7 @@ nsMenuBarListener::KeyDown(nsIDOMEvent* aKeyEvent)
if (active)
mMenuBarFrame->Enter();
}
#ifndef XP_UNIX
else if (active || altKeyWasDown) {
// Get the character code.
nsCOMPtr<nsIDOMKeyEvent> keyEvent = do_QueryInterface(aKeyEvent);
@ -154,6 +157,8 @@ nsMenuBarListener::KeyDown(nsIDOMEvent* aKeyEvent)
mMenuBarFrame->ShortcutNavigation(charCode, active);
}
}
#endif
if (active) {
mKeyboardNavigationActive = PR_TRUE;
aKeyEvent->PreventBubble();
@ -197,13 +202,10 @@ nsresult
nsMenuBarListener::Blur(nsIDOMEvent* aEvent)
{
if (mKeyboardNavigationActive && mMenuBarFrame->IsActive()) {
//if(gRollupListener)
// gRollupListener->Rollup();
mMenuBarFrame->ToggleMenuActiveState();
mMenuBarFrame->Escape();
mAltKeyDown = PR_FALSE;
mKeyboardNavigationActive = PR_FALSE;
//mMenuBarFrame->ToggleMenuActiveState();
}
return NS_OK; // means I am NOT consuming event
@ -213,16 +215,11 @@ nsMenuBarListener::Blur(nsIDOMEvent* aEvent)
nsresult
nsMenuBarListener::MouseDown(nsIDOMEvent* aMouseEvent)
{
PRBool isOpen;
//mMenuBarFrame->MenuIsOpen(&isOpen);
if (!mMenuBarFrame->IsOpen() && mMenuBarFrame->IsActive()) {
//if(gRollupListener)
// gRollupListener->Rollup();
mMenuBarFrame->ToggleMenuActiveState();
mMenuBarFrame->Escape();
mAltKeyDown = PR_FALSE;
mKeyboardNavigationActive = PR_FALSE;
//mMenuBarFrame->ToggleMenuActiveState();
}
return NS_OK; // means I am NOT consuming event
}
@ -232,13 +229,10 @@ nsresult
nsMenuBarListener::MouseUp(nsIDOMEvent* aMouseEvent)
{
if (!mMenuBarFrame->IsOpen() && mMenuBarFrame->IsActive()) {
//if(gRollupListener)
// gRollupListener->Rollup();
mMenuBarFrame->ToggleMenuActiveState();
mMenuBarFrame->Escape();
mKeyboardNavigationActive = PR_FALSE;
mAltKeyDown = PR_FALSE;
//mMenuBarFrame->ToggleMenuActiveState();
}
return NS_OK; // means I am NOT consuming event
}
@ -246,13 +240,11 @@ nsMenuBarListener::MouseUp(nsIDOMEvent* aMouseEvent)
nsresult
nsMenuBarListener::MouseClick(nsIDOMEvent* aMouseEvent)
{
PRBool isOpen;
if (!mMenuBarFrame->IsOpen() && mMenuBarFrame->IsActive()) {
mMenuBarFrame->ToggleMenuActiveState();
mMenuBarFrame->Escape();
mKeyboardNavigationActive = PR_FALSE;
mAltKeyDown = PR_FALSE;
//mMenuBarFrame->ToggleMenuActiveState();
}
return NS_OK; // means I am NOT consuming event

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

@ -297,6 +297,7 @@ nsTitledButtonFrame::Init(nsIPresContext* aPresContext,
// but the mTitle doesn't have the character
mAccesskeyIndex = -1;
#ifndef XP_UNIX
nsAutoString accesskey;
mContent->GetAttribute(kNameSpaceID_None, nsXULAtoms::accesskey,
accesskey);
@ -310,6 +311,7 @@ nsTitledButtonFrame::Init(nsIPresContext* aPresContext,
mTitle += tmpstring;
}
}
#endif
return rv;
}
@ -796,7 +798,7 @@ void
nsTitledButtonFrame::UpdateAccessUnderline()
{
mAccesskeyIndex = -1;
#ifndef XP_UNIX
nsAutoString accesskey;
mContent->GetAttribute(kNameSpaceID_None, nsXULAtoms::accesskey,
accesskey);
@ -805,6 +807,7 @@ nsTitledButtonFrame::UpdateAccessUnderline()
mAccesskeyIndex = mCroppedTitle.Find(accesskey, PR_TRUE);
mNeedsAccessUpdate = PR_TRUE;
#endif
}
NS_IMETHODIMP

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

@ -381,7 +381,6 @@ nsTreeFrame::Reflow(nsIPresContext* aPresContext,
mSlatedForReflow = PR_FALSE;
if (!mSuppressReflow) {
nsRect rect;
GetRect(rect);
if (rect.width != aReflowState.mComputedWidth && aReflowState.reason == eReflowReason_Resize) {
@ -395,11 +394,6 @@ nsTreeFrame::Reflow(nsIPresContext* aPresContext,
}
rv = nsTableFrame::Reflow(aPresContext, aDesiredSize, aReflowState, aStatus);
}
else
{
aStatus = NS_FRAME_COMPLETE;
}
if (aReflowState.mComputedWidth != NS_UNCONSTRAINEDSIZE)
aDesiredSize.width = aReflowState.mComputedWidth +

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

@ -85,9 +85,6 @@ public:
PRBool ContainsFlexibleColumn(PRInt32 aStartIndex, PRInt32 aEndIndex, nsTableColFrame** aResult);
void SuppressReflow() { mSuppressReflow = PR_TRUE; };
void UnsuppressReflow() { mSuppressReflow = PR_FALSE; };
PRInt32 GetInsertionIndex(nsIFrame *aFrame);
// nsISelfScrollingFrame interface
@ -112,7 +109,6 @@ protected: // Data Members
nsTreeTwistyListener* mTwistyListener;
PRInt32 mGeneration;
PRBool mUseGeneration;
PRBool mSuppressReflow;
PRInt32 mFixedRows;
PRBool mReflowStopped;
}; // class nsTreeFrame

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

@ -290,7 +290,7 @@ nsTreeRowFrame::HandleHeaderDragEvent(nsIPresContext* aPresContext,
nsTreeFrame* treeFrame = (nsTreeFrame*)tableFrame;
// Until we finish all of our batched operations, suppress all reflow.
treeFrame->SuppressReflow();
// XXX How to suppress?
PRInt32 columnCount = treeFrame->GetColCount();
PRInt32* colWidths = new PRInt32[columnCount];
@ -406,7 +406,6 @@ nsTreeRowFrame::HandleHeaderDragEvent(nsIPresContext* aPresContext,
mFlexingCol->GetContent(getter_AddRefs(flexContent));
if (flexContent) {
treeFrame->SetUseGeneration(PR_FALSE); // Cached rows have to reflow.
treeFrame->UnsuppressReflow();
colWidth = flexWidth - delta;
sprintf(ch,"%d*", colWidth);

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

@ -701,10 +701,13 @@ nsTreeRowGroupFrame::PositionChanged(nsIPresContext* aPresContext, PRInt32 aOldI
mCurrentIndex = aNewIndex;
if (mContentChain) {
// XXX This could cause problems because of async reflow.
// Eventually we need to make the code smart enough to look at a content chain
// when building ANOTHER content chain.
/*if (mContentChain) {
NS_ERROR("This is bad!");
return NS_OK;
}
}*/
// Get our row count.
PRInt32 rowCount;