MCPcopy Create free account
hub / github.com/bailey27/cppcryptfs / OnDeviceChange

Method OnDeviceChange

cppcryptfs/ui/CryptPropertySheet.cpp:368–385  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

366
367
368BOOL CCryptPropertySheet::OnDeviceChange( UINT nEventType, DWORD_PTR dwData )
369{
370 if (nEventType == DBT_DEVICEARRIVAL || nEventType == DBT_DEVICEREMOVECOMPLETE) {
371
372 PDEV_BROADCAST_HDR pHdr = (PDEV_BROADCAST_HDR)dwData;
373
374 if (pHdr->dbch_devicetype == DBT_DEVTYP_VOLUME) {
375 PDEV_BROADCAST_VOLUME pVolHdr = (PDEV_BROADCAST_VOLUME)dwData;
376 if ((pVolHdr->dbcv_unitmask & theApp.m_mountedLetters) != pVolHdr->dbcv_unitmask) {
377 CCryptPropertyPage *page = (CCryptPropertyPage*)GetPage(m_nMountPageIndex);
378 if (page)
379 page->DeviceChange();
380 }
381 }
382 }
383
384 return CPropertySheet::OnDeviceChange(nEventType, dwData);
385}
386
387
388void CCryptPropertySheet::OnEndSession(BOOL bEnding)

Callers

nothing calls this directly

Calls 1

DeviceChangeMethod · 0.45

Tested by

no test coverage detected