Add bundle_info.h.
Use it wherever the bundle identifier is needed.
Change-Id: I4970a732220526692227058e0b7e51d1595f4765
diff --git a/VP8EncoderGui.c b/VP8EncoderGui.c
index 7059150..d8f30a2 100644
--- a/VP8EncoderGui.c
+++ b/VP8EncoderGui.c
@@ -17,6 +17,7 @@
#include <stdio.h>
+#include "bundle_info.h"
#include "log.h"
#include "Raw_debug.h"
@@ -29,8 +30,6 @@
#include "VP8Encoder.h"
#include "VP8EncoderGui.h"
-#include "WebMExportStructs.h"
-#include "WebMExportGuiVideo.h"
static void setUIntFromControl(UInt32 * i, WindowRef w, int id)
{
@@ -147,7 +146,7 @@
CFBundleRef bundle = NULL;
IBNibRef nibRef = NULL;
- bundle = CFBundleGetBundleWithIdentifier(CFSTR(kWebMExportBundleID));
+ bundle = CFBundleGetBundleWithIdentifier(CFSTR(kWebmBundleId));
if (bundle == NULL)
{
diff --git a/WebM.xcodeproj/project.pbxproj b/WebM.xcodeproj/project.pbxproj
index b6f16eb..e95b20a 100644
--- a/WebM.xcodeproj/project.pbxproj
+++ b/WebM.xcodeproj/project.pbxproj
@@ -76,6 +76,7 @@
10D73AE6124D4A2A00673FEC /* mkvreaderqt.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = mkvreaderqt.hpp; sourceTree = "<group>"; };
374E1CE713FD7BFB00A14F1C /* libvpx.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = libvpx.xcodeproj; path = external/libvpx.xcodeproj; sourceTree = "<group>"; };
374E201313FD891100A14F1C /* libwebm.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = libwebm.xcodeproj; path = external/libwebm.xcodeproj; sourceTree = "<group>"; };
+ 6A0610C214F731A4003AC5D2 /* bundle_info.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = bundle_info.h; sourceTree = "<group>"; };
8D01CCD10486CAD60068D4B7 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist; path = Info.plist; sourceTree = "<group>"; };
8D01CCD20486CAD60068D4B7 /* AWebM.component */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = AWebM.component; sourceTree = BUILT_PRODUCTS_DIR; };
BB124ADE12392B0300A26F24 /* VP8EncoderGui.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = VP8EncoderGui.h; sourceTree = "<group>"; };
@@ -307,6 +308,7 @@
BB9815BC11FF1C5F0031AA75 /* Raw_debug.h */,
BB9815BD11FF1C5F0031AA75 /* VP8Codec_Prefix.pch */,
BB9815BE11FF1C5F0031AA75 /* VP8CodecVersion.h */,
+ 6A0610C214F731A4003AC5D2 /* bundle_info.h */,
);
name = Common;
sourceTree = "<group>";
diff --git a/WebMExportGui.c b/WebMExportGui.c
index 549dec0..9db7180 100644
--- a/WebMExportGui.c
+++ b/WebMExportGui.c
@@ -16,6 +16,7 @@
#include <QuickTimeComponents.h>
#endif
+#include "bundle_info.h"
#include "log.h"
#include "WebMExportVersions.h"
@@ -25,7 +26,7 @@
CFBundleRef bundle = NULL;
IBNibRef nibRef = NULL;
- bundle = CFBundleGetBundleWithIdentifier(CFSTR(kWebMExportBundleID));
+ bundle = CFBundleGetBundleWithIdentifier(CFSTR(kWebmBundleId));
if (bundle == NULL)
{
diff --git a/WebMExportGuiVideo.h b/WebMExportGuiVideo.h
index 0dc96ff..1696c0b 100644
--- a/WebMExportGuiVideo.h
+++ b/WebMExportGuiVideo.h
@@ -10,13 +10,8 @@
#ifndef _WEBMEXPORTGUIVIDEO_H_
#define _WEBMEXPORTGUIVIDEO_H_ 1
-#if !defined(kWebMExportBundleID)
-#define kWebMExportBundleID "org.webmproject.webmquicktime.component"
-#endif
-
ComponentResult getDefaultVP8Atom(WebMExportGlobalsPtr globals);
ComponentResult OpenVP8Dlg(WebMExportGlobalsPtr globals, WindowRef window);
ComponentResult getVideoComponentInstace(WebMExportGlobalsPtr glob, ComponentInstance *videoCI);
-
#endif
diff --git a/bundle_info.h b/bundle_info.h
new file mode 100644
index 0000000..496353c
--- /dev/null
+++ b/bundle_info.h
@@ -0,0 +1,14 @@
+// Copyright (c) 2012 The WebM project authors. All Rights Reserved.
+//
+// Use of this source code is governed by a BSD-style license
+// that can be found in the LICENSE file in the root of the source
+// tree. An additional intellectual property rights grant can be found
+// in the file PATENTS. All contributing project authors may
+// be found in the AUTHORS file in the root of the source tree.
+
+#if !defined WEBMQUICKTIME_BUNDLE_INFO_H_
+#define WEBMQUICKTIME_BUNDLE_INFO_H_
+
+#define kWebmBundleId "org.webmproject.webmquicktime.component"
+
+#endif // WEBMQUICKTIME_BUNDLE_INFO_H_