rejetto forum

Software => HFS ~ HTTP File Server => Beta => Topic started by: rejetto on October 19, 2008, 05:22:54 PM

Title: Testing build #209
Post by: rejetto on October 19, 2008, 05:22:54 PM
download @ www.dovedove.it/hfs/hfs209.exe

what's new
+ permissions menu are now nicer
- "Max sim. downloads from single address" broken in recent build
- erroneous handling of null chars in the URL
- problems with multiple versions and run-on-startup www.rejetto.com/forum/?topic=6236
- accounts sorting is no more case sensitive
Title: Re: Testing build #209
Post by: TCube on October 19, 2008, 05:44:10 PM
8 pm ! Another release  ??? I would say the other way around - " Thanks God tomorrow it's Monday"
Title: Re: Testing build #209
Post by: rejetto on October 19, 2008, 06:28:29 PM
i don't understand, what other release are you talking about?
prev build was 3 days ago.
Title: Re: Testing build #209
Post by: TCube on October 19, 2008, 07:18:41 PM
Just  a joke  ;) I meant between VO & VF .  Just scrap my comments
Title: Re: Testing build #209
Post by: rejetto on October 19, 2008, 09:32:43 PM
ok, got it. i always told SP to wait 24 hours at least :)
Title: Re: Testing build #209
Post by: rejetto on October 20, 2008, 03:28:40 PM
Falcon4 moved to www.rejetto.com/forum/?topic=6246
Title: Re: Testing build #209
Post by: rejetto on October 21, 2008, 01:14:06 PM
i disabled that code because it doesn't handle ampersand/accelerators correctly.
drawtext() would handle it perfectly, but didn't work for me (as i wrote in the comments).
from the screenshot i cannot say if you solved the problem. did you?
Title: Re: Testing build #209
Post by: Mars on October 21, 2008, 01:20:51 PM
sorry i delete my last post before you post the post above >:(

i found some info on the web and test with this draw line

//drawText(cnv.handle, @s[1], -1, r, DT_SINGLELINE+DT_LEFT+DT_VCENTER);
DrawText(cnv.Handle, PChar(mi.hint), StrLen(PChar(mi.hint)), r, DT_CENTER or DT_NOPREFIX or DT_SINGLELINE);


Quote
procedure buildPermissionsMenu(parent:Tmenuitem; action:TfileAction);

   function getlinked(i:integer; act: TfileAction):string;      //add by mars  all this function
   var
     f:Tfile;
     a, other: Paccount;
   begin
   a:=@accounts;
   result:='';
   f:=selectedfile;
   if f=nil then exit;
   if not stringExists(USER_ANY_ACCOUNT, f.accounts[act]) then
     begin
     other:=findEnabledLinkedAccount(a, f.accounts[act]);
     if other = NIL then exit;
     if other <> a then
       result:=' --> via '+other.user;
     end;
   end;         //add by mars  all this function


   procedure addGroups(doGroups:boolean);
    var
      mi: Tmenuitem;
      i: integer;
    begin
    for i:=0 to length(accounts)-1 do
      with accounts do
        begin
        if group <> doGroups then continue;
        mi:=newItem(user, 0, not anyone and stringExists(user,all_accounts[action]), not anyone and enabled, permissionMenuClick, 0, '');
       mi.hint:=user+getlinked(i,action);          //add by mars                                       
        mi.onDrawItem:=mainfrm.menuDraw;      //add by mars
        mi.OnMeasureItem:=mainfrm.menuMeasure;     //add by mars
        mi.ImageIndex:=if_(length(mi.hint)>length(mi.caption), 5, accountIcon(mi.Checked, group));  //mod by mars
        mi.default:=mi.Checked;
        parent.add(mi);
        end;
    end;

Quote
//** this was meant to paint the normal items, to get both icon and check-mark. but drawtext() doesn't work. :-S
cnv.fillRect(r);
//cnv.textOut(r.Left+images.Width*2, r.Top, mi.caption);

inc(r.left, images.width*2);
//drawText(cnv.handle, @s[1], -1, r, DT_SINGLELINE+DT_LEFT+DT_VCENTER);
DrawText(cnv.Handle, PChar(mi.hint), StrLen(PChar(mi.hint)), r, DT_CENTER or DT_NOPREFIX or DT_SINGLELINE);
dec(r.left, images.width*2);

and i obtain this image

It is Silentpliz who is going to be satisfied with this appearance :D :D ;)
Title: Re: Testing build #209
Post by: bacter on October 22, 2008, 08:09:32 PM
there is bug deleting user accounts: accounts are removed, but passwords are shuffled!
Seems that removing an account, the associated password is not removed, but associated to next account, and so downwards in the list.
Title: Re: Testing build #209
Post by: Mars on October 22, 2008, 08:24:27 PM
I confirm : they are all the properties which are copied out moved there and this is due to a bad synchronistation of saving and restitition of the parameters of an account during the change of selection. I recommend by waiting to move the account to be deleted at the end of list before erasing it


Quote
procedure ToptionsFrm.deleteAccount(i:integer=-1);
begin
if i < 0 then
   begin
  i:=accountsBox.itemIndex;
  if i < 0 then exit;
    if msgDlg('Delete?', MB_ICONQUESTION+MB_YESNO) = IDNO then
     exit;
  end;
// shift
for i:=i+1 to length(tempAccounts)-1 do
  tempAccounts[i-1]:=tempAccounts[ i ];
// shorten
i:=length(tempAccounts)-1;
setlength(tempAccounts, i);
i:=accountsBox.itemIndex;                          //this correct one minnor display bug
accountsBox.items.delete(0);
accountsBox.items.delete(i);
accountsbox.itemIndex:=min(i,accountsbox.items.Count-1);

loadAccountProperties();          //add by mars
accountsBox.invalidate();
end; // deleteAccount

A small visual inconvenience: when we add an account new, the parameters of the former are still visible at the time of reappointing this account new, the girl modif below avoids it
Quote
procedure ToptionsFrm.addaccountBtnClick(Sender: TObject);
var
  i: integer;
  a: Taccount;
begin
a.user:=getUniqueName('new user', userExists);
a.pwd:='';
a.enabled:=TRUE;
a.noLimits:=FALSE;
a.redir:='';

i:=length(tempAccounts);
setLength(tempAccounts, i+1);
tempAccounts[ i ]:=a;
accountsBox.count:=i+1;
accountsBox.ItemIndex:=i;
loadAccountProperties();         //add by mars
renaccountBtnClick(sender);
end;

Small personal addition:

DoubleClick on an account to rename it,
Quote
procedure ToptionsFrm.accountsBoxDblClick(Sender: TObject);
begin
renaccountBtn.Click();
end;

The touch INS allows to add an account ,

Reminder: the arrows UP an DOWN allow to change the accounts selection,
Addition of the touch ALT+UP/DOWN to move an account in the list.

Quote
procedure ToptionsFrm.accountsBoxKeyUp(Sender: TObject; var Key: Word; Shift: TShiftState);
begin
if inPlaceEditBox.Visible then exit;
if shift = [] then
    case key of
    VK_F2: renaccountBtn.click();
    VK_DELETE: deleteAccount();
    VK_INSERT: addaccountBtn.Click();
    end;
if shift = [ssAlt] then
    case key of
    VK_UP: upBtn.click();
    VK_DOWN: downBtn.Click();
    end;
end;

another visual bug corrected by add
Quote
procedure ToptionsFrm.accountsBoxMouseDown(Sender: TObject;
  Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
begin
if accountsBox.ItemAtPos(point(x,y), TRUE) < 0 then
   accountsbox.itemindex:=accountsbox.count-1;
end;
Title: Re: Testing build #209
Post by: mamingxing on October 28, 2008, 05:54:25 AM
Thank you for your harding working.
I'm using the 209 beta. But I found HFS will be not stable when the connection is  too much or the data flow rate is too high. I can't access the server via IE when it's down.
Anyone could give me a hand please?
Title: Re: Testing build #209
Post by: rejetto on October 28, 2008, 05:14:40 PM
you should check if your cpu/network resources are over.
in such case you may may not able to access the server.