View Issue Details

IDProjectCategoryView StatusLast Update
0004387JEDI VCL04 Feature Requestpublic2008-07-23 06:33
ReportersnwAssigned Toobones 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product Version 
Target VersionFixed in Version3.34 
Summary0004387: enable TJvDropTarget to receive unicode filenames
Descriptionfunction TJvDropTarget.GetFilenamesW(List: TWStringList): Integer;
var
  DragH: Integer;
  Medium: TStgMedium;
  Name: widestring;
  I, Count, Len: Integer;
begin
  Result := 0;
  if FDataObject.GetData(FileDropFormatEtc, Medium) = S_OK then
    try
      try
        DragH := Integer(GlobalLock(Medium.hGlobal));
        try
          Count := DragQueryFileW(DragH, Cardinal(-1), nil, 0);
          if List <> nil then
            for I := 0 to Count - 1 do
            begin
              Len := DragQueryFileW(DragH, I, nil, 0);
              if Len > 0 then
              begin
                SetLength(Name, Len + 1);
                DragQueryFileW(DragH, I, PwideChar(Name), Len + 1);
                SetLength(Name, Len);
                List.Append(Name);
              end;
            end;
          Result := Count;
        finally
          GlobalUnlock(Medium.hGlobal);
        end;
      finally
        ReleaseStgMedium(Medium);
      end;
    except
      Result := 0;
    end;
end;
Additional Informationi have oryginally written this with TtntStringList but jedi TWStringList should do.
TagsNo tags attached.

Activities

obones

2008-07-23 06:32

administrator   ~0014413

Thanks, this is now in SVN

Issue History

Date Modified Username Field Change
2008-07-01 09:15 snw New Issue
2008-07-15 01:07 obones Status new => acknowledged
2008-07-23 06:32 obones Status acknowledged => resolved
2008-07-23 06:32 obones Fixed in Version => Daily / SVN
2008-07-23 06:32 obones Resolution open => fixed
2008-07-23 06:32 obones Assigned To => obones
2008-07-23 06:32 obones Note Added: 0014413