author Ted Mielczarek <>
Thu, 14 Dec 2017 10:20:33 -0600
changeset 448896 b5c9bb05168d5ce9c92f500d25516b19d0a3062a
parent 416428 6a629adbb62a299d7208373d1c6f375149d2afdb
child 492214 f8bf4f08ececa908442535c90aa44e60712039c6
permissions -rw-r--r--
bug 1401647 - use a 64-bit Rust toolchain for win32 builds. r=rillian We currently use a 32-bit Rust toolchain for win32 builds, but this can lead to OOM situations. This patch makes win32 builds use a 64-bit Rust toolchain, which requires a little bit of extra configuration because rustc needs to be able to find a link.exe that produces 64-bit binaries for building things like build scripts, which are host binaries. We will now generate a batch file that sets LIB to the paths to 64-bit libraries and invokes the x64-targeting link.exe, and add a section to the .cargo/config file to instruct cargo to use that batch file as the linker when producing 64-bit binaries. MozReview-Commit-ID: 9vKBbm7Gvra

/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/* 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 */


  The XUL "controllers" object.


#ifndef nsXULControllers_h__
#define nsXULControllers_h__

#include "nsCOMPtr.h"
#include "nsTArray.h"
#include "nsWeakPtr.h"
#include "nsIControllers.h"
#include "nsCycleCollectionParticipant.h"

/* non-XPCOM class for holding controllers and their IDs */
class nsXULControllerData
                            nsXULControllerData(uint32_t inControllerID, nsIController* inController)
                            : mControllerID(inControllerID)
                            , mController(inController)

                            ~nsXULControllerData() {}

    uint32_t                GetControllerID()   { return mControllerID; }

    nsresult                GetController(nsIController **outController)
                              NS_IF_ADDREF(*outController = mController);
                              return NS_OK;

    uint32_t                mControllerID;
    nsCOMPtr<nsIController> mController;

nsresult NS_NewXULControllers(nsISupports* aOuter, REFNSIID aIID, void** aResult);

class nsXULControllers : public nsIControllers
    friend nsresult
    NS_NewXULControllers(nsISupports* aOuter, REFNSIID aIID, void** aResult);


    virtual ~nsXULControllers(void);

    void        DeleteControllers();

    nsTArray<nsXULControllerData*>   mControllers;
    uint32_t                         mCurControllerID;

#endif // nsXULControllers_h__