userlibandfileserver/fileserver/shostmassstorage/server/protocol/cscsiprotocol.cpp
equal
deleted
inserted
replaced
262 void CScsiProtocol::GetCapacityL(TCapsInfo& aCapsInfo) |
262 void CScsiProtocol::GetCapacityL(TCapsInfo& aCapsInfo) |
263 { |
263 { |
264 __MSFNLOG |
264 __MSFNLOG |
265 if (!IsConnected()) |
265 if (!IsConnected()) |
266 { |
266 { |
267 DoScsiReadyCheckEventL(); |
267 if (!DoScsiReadyCheckEventL()) |
|
268 return; |
268 } |
269 } |
269 |
270 |
270 if (!iSbcInterface) |
271 if (!iSbcInterface) |
271 { |
272 { |
272 aCapsInfo.iMediaType = EMediaCdRom; |
273 aCapsInfo.iMediaType = EMediaCdRom; |
798 iSbcInterface->StartStopUnitL(ETrue); |
799 iSbcInterface->StartStopUnitL(ETrue); |
799 } |
800 } |
800 } |
801 } |
801 |
802 |
802 |
803 |
803 void CScsiProtocol::DoScsiReadyCheckEventL() |
804 TBool CScsiProtocol::DoScsiReadyCheckEventL() |
804 { |
805 { |
805 __MSFNLOG |
806 __MSFNLOG |
806 TInt err = KErrNone; |
807 TInt err = KErrNone; |
807 |
808 |
808 if(iRemovableMedia || iState != EConnected) |
809 if(iRemovableMedia || iState != EConnected) |
831 iState = EConnected; |
832 iState = EConnected; |
832 __SCSIPRINT(_L("** Connected Notification **")); |
833 __SCSIPRINT(_L("** Connected Notification **")); |
833 iMediaChangeNotifier.DoNotifyL(); |
834 iMediaChangeNotifier.DoNotifyL(); |
834 } |
835 } |
835 } |
836 } |
|
837 return err = KErrNone ? ETrue : EFalse; |
836 } |
838 } |
837 |
839 |
838 |
840 |
839 RMediaChangeNotifier::RMediaChangeNotifier() |
841 RMediaChangeNotifier::RMediaChangeNotifier() |
840 : iRegistered(EFalse) |
842 : iRegistered(EFalse) |