2017-10-27 20:33:53 +03:00
|
|
|
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
|
|
|
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
1999-04-22 02:46:15 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
|
|
|
|
Eric D Vaughan
|
|
|
|
A frame that can have multiple children. Only one child may be displayed at one time. So the
|
|
|
|
can be flipped though like a deck of cards.
|
2017-07-06 15:00:35 +03:00
|
|
|
|
1999-04-22 02:46:15 +04:00
|
|
|
**/
|
|
|
|
|
|
|
|
#ifndef nsDeckFrame_h___
|
|
|
|
#define nsDeckFrame_h___
|
|
|
|
|
2012-09-14 20:10:08 +04:00
|
|
|
#include "mozilla/Attributes.h"
|
2000-03-31 11:02:06 +04:00
|
|
|
#include "nsBoxFrame.h"
|
1999-04-22 02:46:15 +04:00
|
|
|
|
2017-05-02 04:50:16 +03:00
|
|
|
class nsDeckFrame final : public nsBoxFrame
|
1999-04-22 02:46:15 +04:00
|
|
|
{
|
|
|
|
public:
|
2011-10-27 03:57:55 +04:00
|
|
|
NS_DECL_QUERYFRAME
|
2017-05-26 13:11:11 +03:00
|
|
|
NS_DECL_FRAMEARENA_HELPERS(nsDeckFrame)
|
1999-04-22 02:46:15 +04:00
|
|
|
|
2005-10-27 01:46:39 +04:00
|
|
|
friend nsIFrame* NS_NewDeckFrame(nsIPresShell* aPresShell,
|
2018-03-22 21:20:41 +03:00
|
|
|
ComputedStyle* aStyle);
|
1999-05-10 01:46:24 +04:00
|
|
|
|
2014-02-18 11:47:48 +04:00
|
|
|
virtual nsresult AttributeChanged(int32_t aNameSpaceID,
|
2017-10-03 01:05:19 +03:00
|
|
|
nsAtom* aAttribute,
|
2015-03-21 19:28:04 +03:00
|
|
|
int32_t aModType) override;
|
1999-04-22 02:46:15 +04:00
|
|
|
|
2016-04-21 07:28:35 +03:00
|
|
|
NS_IMETHOD DoXULLayout(nsBoxLayoutState& aState) override;
|
1999-10-30 02:13:57 +04:00
|
|
|
|
2013-02-14 15:12:27 +04:00
|
|
|
virtual void BuildDisplayList(nsDisplayListBuilder* aBuilder,
|
2015-03-21 19:28:04 +03:00
|
|
|
const nsDisplayListSet& aLists) override;
|
2006-01-26 05:29:17 +03:00
|
|
|
|
2014-08-02 16:22:06 +04:00
|
|
|
virtual void RemoveFrame(ChildListID aListID,
|
2015-03-21 19:28:04 +03:00
|
|
|
nsIFrame* aOldFrame) override;
|
2014-08-02 16:22:06 +04:00
|
|
|
|
2013-02-14 15:12:27 +04:00
|
|
|
virtual void BuildDisplayListForChildren(nsDisplayListBuilder* aBuilder,
|
2015-03-21 19:28:04 +03:00
|
|
|
const nsDisplayListSet& aLists) override;
|
2017-04-30 18:30:08 +03:00
|
|
|
|
2014-05-25 02:20:40 +04:00
|
|
|
virtual void Init(nsIContent* aContent,
|
|
|
|
nsContainerFrame* aParent,
|
2015-03-21 19:28:04 +03:00
|
|
|
nsIFrame* aPrevInFlow) override;
|
2000-06-22 04:48:49 +04:00
|
|
|
|
2014-01-06 03:31:14 +04:00
|
|
|
#ifdef DEBUG_FRAME_DUMP
|
2015-03-21 19:28:04 +03:00
|
|
|
virtual nsresult GetFrameName(nsAString& aResult) const override
|
1) implememted box reflow coelescing.
2) implemented gfx scrollbars for list boxes
3) fixed progess meter to be an animated gif
4) fixed bugs 23521, 24721, 19114, 20546, 24385, 24457, 23156, 20226, 22543
-r hyatt, troy, rod
2000-02-10 01:02:40 +03:00
|
|
|
{
|
2001-11-14 04:33:42 +03:00
|
|
|
return MakeFrameName(NS_LITERAL_STRING("Deck"), aResult);
|
1) implememted box reflow coelescing.
2) implemented gfx scrollbars for list boxes
3) fixed progess meter to be an animated gif
4) fixed bugs 23521, 24721, 19114, 20546, 24385, 24457, 23156, 20226, 22543
-r hyatt, troy, rod
2000-02-10 01:02:40 +03:00
|
|
|
}
|
2000-04-12 03:55:15 +04:00
|
|
|
#endif
|
1) implememted box reflow coelescing.
2) implemented gfx scrollbars for list boxes
3) fixed progess meter to be an animated gif
4) fixed bugs 23521, 24721, 19114, 20546, 24385, 24457, 23156, 20226, 22543
-r hyatt, troy, rod
2000-02-10 01:02:40 +03:00
|
|
|
|
2018-03-22 21:20:41 +03:00
|
|
|
explicit nsDeckFrame(ComputedStyle* aStyle);
|
2000-04-05 04:19:00 +04:00
|
|
|
|
2011-10-27 03:57:55 +04:00
|
|
|
nsIFrame* GetSelectedBox();
|
|
|
|
|
1999-04-22 02:46:15 +04:00
|
|
|
protected:
|
|
|
|
|
2011-10-27 03:57:55 +04:00
|
|
|
void IndexChanged();
|
2012-08-22 19:56:38 +04:00
|
|
|
int32_t GetSelectedIndex();
|
2012-08-06 07:00:57 +04:00
|
|
|
void HideBox(nsIFrame* aBox);
|
1999-04-22 02:46:15 +04:00
|
|
|
|
1999-04-26 00:07:45 +04:00
|
|
|
private:
|
|
|
|
|
2012-08-22 19:56:38 +04:00
|
|
|
int32_t mIndex;
|
1999-04-26 00:07:45 +04:00
|
|
|
|
1999-04-22 02:46:15 +04:00
|
|
|
}; // class nsDeckFrame
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|