Obsolete Members for QThreadPool

以下成員源於類 QThreadPool 已過時。 提供它們是為使舊源代碼能繼續工作。強烈建議不要在新代碼中使用它們。

公共函數

(obsolete) void cancel (QRunnable * runnable )

成員函數文檔編製

void QThreadPool:: cancel ( QRunnable * runnable )

此函數已過時。提供它是為使舊源代碼能繼續工作。強烈建議不要在新代碼中使用它。

使用 tryTake () instead, but note the different deletion rules.

移除指定 runnable from the queue if it is not yet started. The runnables for which runnable->autoDelete() 返迴 true 被刪除。

該函數在 Qt 5.5 引入。

另請參閱 start () 和 tryTake ().