CEFInterfaceBrowserPopupFeatures.cpp 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. // Engine/Source/Runtime/WebBrowser/Private/CEF/CEFBrowserPopupFeatures.cpp
  2. #include "CEF/CEFInterfaceBrowserPopupFeatures.h"
  3. #if WITH_CEF3
  4. FCEFInterfaceBrowserPopupFeatures::FCEFInterfaceBrowserPopupFeatures()
  5. : X(0)
  6. , bXSet(false)
  7. , Y(0)
  8. , bYSet(false)
  9. , Width(0)
  10. , bWidthSet(false)
  11. , Height(0)
  12. , bHeightSet(false)
  13. , bMenuBarVisible(true)
  14. , bStatusBarVisible(false)
  15. , bToolBarVisible(true)
  16. , bLocationBarVisible(true)
  17. , bScrollbarsVisible(true)
  18. , bResizable(true)
  19. , bIsFullscreen(false)
  20. , bIsDialog(false)
  21. {
  22. }
  23. FCEFInterfaceBrowserPopupFeatures::FCEFInterfaceBrowserPopupFeatures( const CefPopupFeatures& PopupFeatures )
  24. {
  25. X = PopupFeatures.x;
  26. bXSet = PopupFeatures.xSet ? true : false;
  27. Y = PopupFeatures.y;
  28. bYSet = PopupFeatures.ySet ? true : false;
  29. Width = PopupFeatures.width;
  30. bWidthSet = PopupFeatures.widthSet ? true : false;
  31. Height = PopupFeatures.height;
  32. bHeightSet = PopupFeatures.heightSet ? true : false;
  33. bMenuBarVisible = PopupFeatures.menuBarVisible ? true : false;
  34. bStatusBarVisible = PopupFeatures.statusBarVisible ? true : false;
  35. bToolBarVisible = PopupFeatures.toolBarVisible ? true : false;
  36. bScrollbarsVisible = PopupFeatures.scrollbarsVisible ? true : false;
  37. // no longer set by the CEF API so default them here to their historic value
  38. bLocationBarVisible = false;
  39. bResizable = false;
  40. bIsFullscreen = false;
  41. bIsDialog = false;
  42. }
  43. FCEFInterfaceBrowserPopupFeatures::~FCEFInterfaceBrowserPopupFeatures()
  44. {
  45. }
  46. void FCEFInterfaceBrowserPopupFeatures::SetResizable(const bool bResize)
  47. {
  48. bResizable = bResize;
  49. }
  50. int FCEFInterfaceBrowserPopupFeatures::GetX() const
  51. {
  52. return X;
  53. }
  54. bool FCEFInterfaceBrowserPopupFeatures::IsXSet() const
  55. {
  56. return bXSet;
  57. }
  58. int FCEFInterfaceBrowserPopupFeatures::GetY() const
  59. {
  60. return Y;
  61. }
  62. bool FCEFInterfaceBrowserPopupFeatures::IsYSet() const
  63. {
  64. return bYSet;
  65. }
  66. int FCEFInterfaceBrowserPopupFeatures::GetWidth() const
  67. {
  68. return Width;
  69. }
  70. bool FCEFInterfaceBrowserPopupFeatures::IsWidthSet() const
  71. {
  72. return bWidthSet;
  73. }
  74. int FCEFInterfaceBrowserPopupFeatures::GetHeight() const
  75. {
  76. return Height;
  77. }
  78. bool FCEFInterfaceBrowserPopupFeatures::IsHeightSet() const
  79. {
  80. return bHeightSet;
  81. }
  82. bool FCEFInterfaceBrowserPopupFeatures::IsMenuBarVisible() const
  83. {
  84. return bMenuBarVisible;
  85. }
  86. bool FCEFInterfaceBrowserPopupFeatures::IsStatusBarVisible() const
  87. {
  88. return bStatusBarVisible;
  89. }
  90. bool FCEFInterfaceBrowserPopupFeatures::IsToolBarVisible() const
  91. {
  92. return bToolBarVisible;
  93. }
  94. bool FCEFInterfaceBrowserPopupFeatures::IsLocationBarVisible() const
  95. {
  96. return bLocationBarVisible;
  97. }
  98. bool FCEFInterfaceBrowserPopupFeatures::IsScrollbarsVisible() const
  99. {
  100. return bScrollbarsVisible;
  101. }
  102. bool FCEFInterfaceBrowserPopupFeatures::IsResizable() const
  103. {
  104. return bResizable;
  105. }
  106. bool FCEFInterfaceBrowserPopupFeatures::IsFullscreen() const
  107. {
  108. return bIsFullscreen;
  109. }
  110. bool FCEFInterfaceBrowserPopupFeatures::IsDialog() const
  111. {
  112. return bIsDialog;
  113. }
  114. TArray<FString> FCEFInterfaceBrowserPopupFeatures::GetAdditionalFeatures() const
  115. {
  116. TArray<FString> Empty;
  117. return Empty;
  118. }
  119. #endif