1 /* 2 * Copyright 2014, Rene Gollent, rene@gollent.com. 3 * Distributed under the terms of the MIT License. 4 */ 5 6 7 #include "ImageDebugInfoLoadingState.h" 8 9 #include "SpecificImageDebugInfoLoadingState.h" 10 11 12 ImageDebugInfoLoadingState::ImageDebugInfoLoadingState() 13 : 14 fSpecificInfoLoadingState(), 15 fSpecificInfoIndex(0) 16 { 17 } 18 19 20 ImageDebugInfoLoadingState::~ImageDebugInfoLoadingState() 21 { 22 } 23 24 25 bool 26 ImageDebugInfoLoadingState::HasSpecificDebugInfoLoadingState() const 27 { 28 return fSpecificInfoLoadingState.IsSet(); 29 } 30 31 32 void 33 ImageDebugInfoLoadingState::SetSpecificDebugInfoLoadingState( 34 SpecificImageDebugInfoLoadingState* state) 35 { 36 fSpecificInfoLoadingState.SetTo(state, true); 37 } 38 39 40 void 41 ImageDebugInfoLoadingState::ClearSpecificDebugInfoLoadingState() 42 { 43 fSpecificInfoLoadingState = NULL; 44 } 45 46 47 bool 48 ImageDebugInfoLoadingState::UserInputRequired() const 49 { 50 if (HasSpecificDebugInfoLoadingState()) 51 return fSpecificInfoLoadingState->UserInputRequired(); 52 53 return false; 54 } 55 56 57 void 58 ImageDebugInfoLoadingState::SetSpecificInfoIndex(int32 index) 59 { 60 fSpecificInfoIndex = index; 61 } 62