WebALogFileList: TStringList; begin if Assigned(fMain.frmMain) and (bForce or gLogWindow) then begin if bForce and (not frmMain.seLogWindow.Visible) then begin if GetCurrentThreadId = MainThreadID then Self.ShowLogWindow else TThread.Synchronize(nil, @Self.ShowLogWindow); end; New(LogMessage); … WebSep 18, 2024 · Otherwise, the TDataProcessor object stays in memory until the main thread calls TDataProcessor.DoProcess(), which then calls TDataProcessor.ProcessData() and …
多线程问题,好晕!!!只有这么多分数了(63分) WeDelphi Forum
WebJul 2, 2014 · Description. StringList () Initializes a new instance of this StringList class. StringList (IEnumerable) Initializes a new instance of the StringList class with the … WebALogFileList: TStringList; begin if Assigned(fMain.frmMain) and (bForce or gLogWindow) then begin if bForce and (not frmMain.seLogWindow.Visible) then begin if … meaning of hypostasis
Solved: TStringList and multi-thread Experts Exchange
WebDouble Commander is a free cross platform open source file manager with two panels side by side. - doublecmd/uShowMsg.pas at master · doublecmd/doublecmd The reason your code is not thread-safe is that it falls short of protecting all your data from shared access. This is a common misunderstanding in multi-threaded development: "I just need to wrap certain operations with locks and all will be fine." The point is, if your list is shared, you are: 1. Sharing the … See more If you want to write thread-safe code the onus is on youto: 1. Understand the data access paths. 2. Minimise sharing between threads (by far the best bang for … See more I indicated earlier that your locking technique only "might be suitable for your current requirements" because I do not believe you have really given an … See more http://delphibasics.co.uk/RTL.php?Name=TStringList pechang headphones