Bug 1737620 - Fix misc errors in unified builds. r=mstange

Differential Revision: https://phabricator.services.mozilla.com/D129405
This commit is contained in:
Harry Twyford 2021-10-28 14:31:54 +00:00
parent 9ec0a602e7
commit 8035b857db
2 changed files with 4 additions and 7 deletions

View File

@ -7,10 +7,7 @@
#define nsStandaloneNativeMenu_h_
#include "nsIStandaloneNativeMenu.h"
namespace mozilla::widget {
class NativeMenuMac;
}
#include "NativeMenuMac.h"
class nsStandaloneNativeMenu : public nsIStandaloneNativeMenu {
public:

View File

@ -22,7 +22,7 @@
using namespace mozilla;
using mozilla::widget::IconLoader;
static const uint32_t kIconSize = 16;
static const uint32_t kIconHeight = 16;
static const CGFloat kHiDPIScalingFactor = 2.0f;
nsTouchBarInputIcon::nsTouchBarInputIcon(RefPtr<Document> aDocument, TouchBarInput* aInput,
@ -82,7 +82,7 @@ nsresult nsTouchBarInputIcon::SetupIcon(nsCOMPtr<nsIURI> aIconURI) {
if (!mSetIcon) {
// Load placeholder icon.
NSSize iconSize = NSMakeSize(kIconSize, kIconSize);
NSSize iconSize = NSMakeSize(kIconHeight, kIconHeight);
NSImage* placeholder = [MOZIconHelper placeholderIconWithSize:iconSize];
[mButton setImage:placeholder];
[mShareScrubber setButtonImage:placeholder];
@ -118,7 +118,7 @@ nsresult nsTouchBarInputIcon::OnComplete(imgIContainer* aImage) {
// We ask only for the HiDPI images since all Touch Bars are Retina
// displays and we have no need for icons @1x.
NSImage* image = [MOZIconHelper iconImageFromImageContainer:aImage
withSize:NSMakeSize(kIconSize, kIconSize)
withSize:NSMakeSize(kIconHeight, kIconHeight)
computedStyle:nullptr
subrect:mImageRegionRect
scaleFactor:kHiDPIScalingFactor];