nsGfxCheckboxControlFrame.h 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
  2. /* This Source Code Form is subject to the terms of the Mozilla Public
  3. * License, v. 2.0. If a copy of the MPL was not distributed with this
  4. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  5. #ifndef nsGfxCheckboxControlFrame_h___
  6. #define nsGfxCheckboxControlFrame_h___
  7. #include "mozilla/Attributes.h"
  8. #include "nsFormControlFrame.h"
  9. class nsGfxCheckboxControlFrame : public nsFormControlFrame
  10. {
  11. public:
  12. NS_DECL_FRAMEARENA_HELPERS
  13. explicit nsGfxCheckboxControlFrame(nsStyleContext* aContext);
  14. virtual ~nsGfxCheckboxControlFrame();
  15. #ifdef DEBUG_FRAME_DUMP
  16. virtual nsresult GetFrameName(nsAString& aResult) const override {
  17. return MakeFrameName(NS_LITERAL_STRING("CheckboxControl"), aResult);
  18. }
  19. #endif
  20. virtual void BuildDisplayList(nsDisplayListBuilder* aBuilder,
  21. const nsDisplayListSet& aLists) override;
  22. #ifdef ACCESSIBILITY
  23. virtual mozilla::a11y::AccType AccessibleType() override;
  24. #endif
  25. protected:
  26. bool IsChecked();
  27. bool IsIndeterminate();
  28. };
  29. #endif