]>
git.saurik.com Git - apple/mdnsresponder.git/blob - mDNSWindows/DNSServiceBrowser/WindowsCE/Sources/Application.cpp
1 /* -*- Mode: C; tab-width: 4 -*-
3 * Copyright (c) 2002-2004 Apple Computer, Inc. All rights reserved.
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
20 #include "DNSServices.h"
22 #include "BrowserDialog.h"
24 #include "Application.h"
29 static char THIS_FILE
[] = __FILE__
;
32 //===========================================================================================================================
34 //===========================================================================================================================
36 BEGIN_MESSAGE_MAP(Application
, CWinApp
)
37 //{{AFX_MSG_MAP(Application)
38 // NOTE - the ClassWizard will add and remove mapping macros here.
39 // DO NOT EDIT what you see in these blocks of generated code!
43 //===========================================================================================================================
45 //===========================================================================================================================
49 //===========================================================================================================================
51 //===========================================================================================================================
53 Application::Application()
59 //===========================================================================================================================
61 //===========================================================================================================================
63 BOOL
Application::InitInstance()
69 dnsInitialized
= FALSE
;
71 err
= DNSServicesInitialize( kDNSFlagAdvertise
, 0 );
74 AfxMessageBox( IDP_SOCKETS_INIT_FAILED
);
77 dnsInitialized
= TRUE
;
79 // Display the main browser dialog.
84 // Dialog has been closed. Return false to exit the app and not start the app's message pump.
89 DNSServicesFinalize();