Closed Bug 536729 Opened 15 years ago Closed 15 years ago

function nsMsgDBView::GetURIsForSelection returns undefined "uris"

Categories

(Thunderbird :: Toolbars and Tabs, defect)

x86
Windows Vista
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: blinov.dmitry, Unassigned)

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 6.0; ru; rv:1.9.1.6) Gecko/20091201 Firefox/3.5.6 (.NET CLR 3.5.30729)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 6.0; ru; rv:1.9.1.5) Gecko/20091204 Thunderbird/3.0

comm-1-9-1-45f7b889010f\mailnews\base\src\nsMsgDBView.cpp rows 2253 - 2298

in row 2296: *uris = outArray;
outArray allocated and checked for proper memory allocation, but in cycle (rows 2278 - 2294) does not accept any values. 

Reproducible: Always

Steps to Reproduce:
1.from JS:
    var urisIn = new Object();
    var countIn = new Object();
		
    gDBView.getURIsForSelection(countIn, urisIn);
		
    Application.console.log('urisIn[0]: ' + urisIn[0]);

2. from TB:
   select one or more messages, run JS
Actual Results:  
in Error Console found: "urisIn[0]: undefined"

Expected Results:  
string, URI for first selected message
Your js does not seem to be correct. Look at some example uses, for example http://mxr.mozilla.org/comm-central/source/mail/base/content/folderDisplay.js#1911

  let messageArray = this.view.dbView.getURIsForSelection({});
(In reply to comment #1)
Thank you a lot for your ansver. It works. 
My js woked in TB 2.0, but in TB 3.0 API was changed, as I understand now.
Status: UNCONFIRMED → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.