Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
MSDN Library
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

IFrameworkViewSource interface

Defines a factory for view provider objects.

Syntax


public interface IFrameworkViewSource

Members

The IFrameworkViewSource interface has these types of members:

Methods

The IFrameworkViewSource interface has these methods. It also inherits methods from the Object class.

MethodDescription
CreateView A method that returns a view provider object.

 

Remarks

Instances of objects that implement this class are provided to the app object's CoreApplication.Run method when the app starts, which uses it to create the views used by the app. View providers must be attributed as MTAThread.



ref class MyFrameworkViewSource : IFrameworkViewSource
{
public:
    virtual IFrameworkView^ CreateView()
    {
        return ref new MyFrameworkView(); // see IFrameworkView for implementation specifics
    }
};

// ...

[Platform::MTAThread]
int main(Platform::Array<Platform::String^>^)
{
    auto frameworkViewSource = ref new MyFrameworkViewSource();
    Windows::ApplicationModel::Core::CoreApplication::Run(frameworkViewSource);
    return 0;
}

Requirements (Windows 10 device family)

Device family

Universal

API contract

Windows.Foundation.UniversalApiContract, introduced version 1.0

Namespace

Windows.ApplicationModel.Core
Windows::ApplicationModel::Core [C++]

Metadata

Windows.Foundation.UniversalApiContract.winmd

Requirements (Windows 8.x and Windows Phone 8.x)

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8

Namespace

Windows.ApplicationModel.Core
Windows::ApplicationModel::Core [C++]

Metadata

Windows.winmd

Attributes

[Version(0x06020000)]
[WebHostHidden()]

See also

DirectX swap chain implementation sample
IFrameworkView

 

 

Show:
© 2015 Microsoft