Форум Flasher.ru
Ближайшие курсы в Школе RealTime
Список интенсивных курсов: [см.]  
  
Специальные предложения: [см.]  
  
 
Блоги Правила Справка Пользователи Календарь Сообщения за день
 

Вернуться   Форум Flasher.ru > Flash > Общие вопросы о Flash (не затрагивающие ActionScript)

Версия для печати  Отправить по электронной почте    « Предыдущая тема | Следующая тема »  
Опции темы Опции просмотра
 
Создать новую тему Ответ
Старый 31.10.2005, 16:46
regulnet вне форума Посмотреть профиль Отправить личное сообщение для regulnet Найти все сообщения от regulnet
  № 1  
Ответить с цитированием
regulnet

Регистрация: Oct 2005
Сообщений: 4
По умолчанию Проблема со ScrollPane в IE

Собственно сабж: при подгрузке внешнего файла (изображение) в ScrollPane тот не показывется в scrollpane, а ложится поверх. Глюк замечен только в IE и подобных браузерах (коих, согласитесь, большинство у пользователей). При обновлении страницы во 2-ой и последующие разы - все ок. В огненном лисе (fiefox), такой проблемы не возникает в принципе... И тут возникает вопрос: кто виноват и что с этим делать....

Старый 01.11.2005, 18:38
regulnet вне форума Посмотреть профиль Отправить личное сообщение для regulnet Найти все сообщения от regulnet
  № 2  
Ответить с цитированием
regulnet

Регистрация: Oct 2005
Сообщений: 4
ну есть же проблема, господа, вот что я еще нарыл по этой теме:
Flash TechNote
A JPEG loaded into a ScrollPane component displays incorrectly and may generate error
Issue

When loading a JPEG directly into the ScrollPane component, certain images may display incorrectly (for example, the JPEG may display outside of the component borders) or may result in an error. The error indicates a “*** Security Sandbox Violation *** SecurityDomain” error even though cross domain security is not enforced in the authoring environment. The images affected tend to be those which are large in size, those which take some time to load, or a file in which the images switch rapidly.
Solution

To correct the render problem and update the ScrollBars of the ScrollPane, call the setSize method of the ScrollPane component after the image has been loaded. Load a movieClip from the library that will, in turn, load your JPEG image to be able to detect when the image had loaded completely, triggering the setSize method. To workaround these issues do the following:

1. Insert a new MovieClip with a Linkage ID in the library
2. Put a Loader component in this movieClip and assign an instance to it
3. Create an event listener for the Loader Component or use an onEvent Handler to detect the load "complete" event
4. When the event is triggered, target the Parent ScrollPane component, calling the setSize method

Note: You don't actually have to change the dimensions of the ScrollPane, and you can specify the existing width and height values as parameters in the method.

Consider the following example:
On the timeline with ScrollPane instance name “myScrollPane”

var myScrollPane:mx.containers.ScrollPane;
myScrollPane.contentPath = 'Holder_mc';
myScrollPane.content.myLoader.contentPath = "http://<path to your JPEG>";

In the Holder_mc movieClip in the library with Loader instance name “myLoader”

var myLoader:mx.controls.Loader;
var myObj:Object = new Object();
myObj.complete = function(obj) {
obj.target._parent._parent.setSize(obj.target._parent._parent.width, obj.target._parent._parent.height);
};
myLoader.addEventListener("complete", myObj);

Создать новую тему Ответ Часовой пояс GMT +4, время: 23:31.
Быстрый переход
  « Предыдущая тема | Следующая тема »  

Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.


 


Часовой пояс GMT +4, время: 23:31.


Copyright © 1999-2008 Flasher.ru. All rights reserved.
Работает на vBulletin®. Copyright ©2000 - 2026, Jelsoft Enterprises Ltd. Перевод: zCarot
Администрация сайта не несёт ответственности за любую предоставленную посетителями информацию. Подробнее см. Правила.