forked from mirrors/gecko-dev
		
	# ignore-this-changeset Differential Revision: https://phabricator.services.mozilla.com/D36041 --HG-- extra : source : 96b3895a3b2aa2fcb064c85ec5857b7216884556
		
			
				
	
	
		
			28 lines
		
	
	
	
		
			570 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			28 lines
		
	
	
	
		
			570 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
function test() {
 | 
						|
  waitForExplicitFinish();
 | 
						|
 | 
						|
  Services.ww.registerNotification(function notification(
 | 
						|
    aSubject,
 | 
						|
    aTopic,
 | 
						|
    aData
 | 
						|
  ) {
 | 
						|
    if (aTopic == "domwindowopened") {
 | 
						|
      Services.ww.unregisterNotification(notification);
 | 
						|
 | 
						|
      ok(true, "duplicateTabIn opened a new window");
 | 
						|
 | 
						|
      whenDelayedStartupFinished(
 | 
						|
        aSubject,
 | 
						|
        function() {
 | 
						|
          executeSoon(function() {
 | 
						|
            aSubject.close();
 | 
						|
            finish();
 | 
						|
          });
 | 
						|
        },
 | 
						|
        false
 | 
						|
      );
 | 
						|
    }
 | 
						|
  });
 | 
						|
 | 
						|
  duplicateTabIn(gBrowser.selectedTab, "window");
 | 
						|
}
 |