| 1796 | // then requeue |
| 1797 | |
| 1798 | STDMETHODIMP |
| 1799 | CDeferredCommand::Postpone(REFTIME newtime) |
| 1800 | { |
| 1801 | |
| 1802 | // check that this time is not past |
| 1803 | // convert REFTIME to REFERENCE_TIME |
| 1804 | COARefTime convertor(newtime); |
| 1805 | |
| 1806 | // check that the time has not passed |
| 1807 | if (m_pQueue->CheckTime(convertor, IsStreamTime())) |
| 1808 | { |
| 1809 | return VFW_E_TIME_ALREADY_PASSED; |
| 1810 | } |
| 1811 | |
| 1812 | // extract from list |
| 1813 | HRESULT hr = m_pQueue->Remove(this); |
| 1814 | if (FAILED(hr)) |
| 1815 | { |
| 1816 | return hr; |
| 1817 | } |
| 1818 | |
| 1819 | // change time |
| 1820 | m_time = convertor; |
| 1821 | |
| 1822 | // requeue |
| 1823 | hr = m_pQueue->Insert(this); |
| 1824 | |
| 1825 | return hr; |
| 1826 | } |
| 1827 | |
| 1828 | HRESULT |
| 1829 | CDeferredCommand::Invoke() |