Mercurial > projects > dstep
diff dstep/qtkit/QTError.d @ 16:19885b43130e
Huge update, the bridge actually works now
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Sun, 03 Jan 2010 22:06:11 +0100 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/dstep/qtkit/QTError.d Sun Jan 03 22:06:11 2010 +0100 @@ -0,0 +1,93 @@ +/** + * Copyright: Copyright (c) 2009 Jacob Carlborg. + * Authors: Jacob Carlborg + * Version: Initial created: Sep 28, 2009 + * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost Software License 1.0) + */ +module dstep.qtkit.QTError; + +import dstep.foundation.Foundation; +import dstep.objc.bridge.Bridge; +import dstep.objc.objc; +import dstep.qtkit.QTKitDefines; + +import bindings = dstep.qtkit.QTError_bindings; + +private +{ + NSString QTKitErrorDomain_; + NSString QTErrorCaptureInputKey_; + NSString QTErrorCaptureOutputKey_; + NSString QTErrorDeviceKey_; + NSString QTErrorExcludingDeviceKey_; + NSString QTErrorRecordingSuccesfullyFinishedKey_; +} + +NSString QTKitErrorDomain () +{ + if (QTKitErrorDomain_) + return QTKitErrorDomain_; + + return QTKitErrorDomain_ = new NSString(bindings.QTKitErrorDomain); +} + +NSString QTErrorCaptureInputKey () +{ + if (QTErrorCaptureInputKey_) + return QTErrorCaptureInputKey_; + + return QTErrorCaptureInputKey_ = new NSString(bindings.QTErrorCaptureInputKey); +} + +NSString QTErrorCaptureOutputKey () +{ + if (QTErrorCaptureOutputKey_) + return QTErrorCaptureOutputKey_; + + return QTErrorCaptureOutputKey_ = new NSString(bindings.QTErrorCaptureOutputKey); +} + +NSString QTErrorDeviceKey () +{ + if (QTErrorDeviceKey_) + return QTErrorDeviceKey_; + + return QTErrorDeviceKey_ = new NSString(bindings.QTErrorDeviceKey); +} + +NSString QTErrorExcludingDeviceKey () +{ + if (QTErrorExcludingDeviceKey_) + return QTErrorExcludingDeviceKey_; + + return QTErrorExcludingDeviceKey_ = new NSString(bindings.QTErrorExcludingDeviceKey); +} + +NSString QTErrorRecordingSuccesfullyFinishedKey () +{ + if (QTErrorRecordingSuccesfullyFinishedKey_) + return QTErrorRecordingSuccesfullyFinishedKey_; + + return QTErrorRecordingSuccesfullyFinishedKey_ = new NSString(bindings.QTErrorRecordingSuccesfullyFinishedKey); +} + +enum +{ + QTErrorUnknown = -1, + QTErrorIncompatibleInput = 1002, + QTErrorIncompatibleOutput = 1003, + QTErrorInvalidInputsOrOutputs = 1100, + QTErrorDeviceAlreadyUsedbyAnotherSession = 1101, + QTErrorNoDataCaptured = 1200, + QTErrorSessionConfigurationChanged = 1201, + QTErrorDiskFull = 1202, + QTErrorDeviceWasDisconnected = 1203, + QTErrorMediaChanged = 1204, + QTErrorMaximumDurationReached = 1205, + QTErrorMaximumFileSizeReached = 1206, + QTErrorMediaDiscontinuity = 1207, + QTErrorDeviceNotConnected = 1300, + QTErrorDeviceInUseByAnotherApplication = 1301, + QTErrorDeviceExcludedByAnotherDevice = 1302 +} +