From fb793870fe95f1951d7c30ea6068e187b9dededd Mon Sep 17 00:00:00 2001 From: Mark Palange Date: Tue, 23 Dec 2008 19:39:58 +0000 Subject: QAR-1142 merging 1.22 RC0-RC4 changes. svn merge -c 106471 svn+ssh://svn.lindenlab.com/svn/linden/qa/viewer_1-22-106055_merge --- indra/develop.py | 2 +- indra/lib/python/indra/util/llmanifest.py | 3 +- indra/linux_crash_logger/CMakeLists.txt | 5 +- indra/llcharacter/lleditingmotion.cpp | 4 +- indra/llcommon/llerror.cpp | 7 + indra/llcommon/llerrorcontrol.h | 4 +- indra/llcommon/llversionviewer.h | 4 +- indra/llcrashlogger/llcrashlogger.cpp | 69 ++- indra/llimage/llimagejpeg.cpp | 3 +- indra/llmath/llvolume.cpp | 19 +- indra/llrender/llgl.cpp | 35 +- indra/llrender/llgl.h | 2 - indra/llrender/llimagegl.cpp | 4 +- indra/llrender/llrender.cpp | 26 +- indra/llrender/llrender.h | 11 +- indra/llui/llfloater.cpp | 31 +- indra/llui/llfloater.h | 5 + indra/llui/lltexteditor.cpp | 14 +- indra/llui/llview.cpp | 156 +---- indra/llwindow/llwindowwin32.cpp | 6 + indra/mac_crash_logger/CrashReporter.nib/info.nib | 8 +- .../mac_crash_logger/CrashReporter.nib/objects.xib | 59 +- indra/newview/app_settings/settings.xml | 43 +- indra/newview/featuretable.txt | 14 +- indra/newview/featuretable_linux.txt | 2 +- indra/newview/featuretable_mac.txt | 2 +- indra/newview/gpu_table.txt | 41 +- indra/newview/installers/windows/lang_de.nsi | Bin 8262 -> 8260 bytes indra/newview/llappviewer.cpp | 175 +++--- indra/newview/llappviewer.h | 17 +- indra/newview/llappviewerlinux.cpp | 112 ++-- indra/newview/llappviewerlinux.h | 5 +- indra/newview/llappviewermacosx.cpp | 102 +++- indra/newview/llappviewermacosx.h | 3 +- indra/newview/llappviewerwin32.cpp | 96 +++- indra/newview/llappviewerwin32.h | 4 +- indra/newview/llcompilequeue.cpp | 17 +- indra/newview/lldrawpoolbump.cpp | 1 - indra/newview/llfeaturemanager.cpp | 4 +- indra/newview/llfloaterinspect.cpp | 4 +- indra/newview/llfloaterpostcard.cpp | 2 +- indra/newview/llfloatersnapshot.cpp | 42 +- indra/newview/llfloatertopobjects.cpp | 4 +- indra/newview/llinventorymodel.cpp | 2 +- indra/newview/llselectmgr.cpp | 9 +- indra/newview/llselectmgr.h | 2 +- indra/newview/llspatialpartition.cpp | 8 +- indra/newview/llspatialpartition.h | 1 + indra/newview/llstartup.cpp | 58 +- indra/newview/llstartup.h | 1 + indra/newview/lltexlayer.cpp | 104 +--- indra/newview/lltexlayer.h | 35 -- indra/newview/llurlhistory.cpp | 13 +- indra/newview/llviewerassetstorage.cpp | 2 +- indra/newview/llviewerdisplay.cpp | 68 +-- indra/newview/llviewermedia.cpp | 1 + indra/newview/llviewermenu.cpp | 91 +-- indra/newview/llviewermenufile.cpp | 8 +- indra/newview/llviewermessage.cpp | 2 +- indra/newview/llviewerobjectlist.cpp | 11 +- indra/newview/llviewerstats.cpp | 8 +- indra/newview/llviewertexteditor.cpp | 5 +- indra/newview/llviewerwindow.cpp | 23 +- indra/newview/llvoavatar.cpp | 73 ++- indra/newview/llvoavatar.h | 6 +- indra/newview/llvosurfacepatch.cpp | 70 ++- indra/newview/llvovolume.cpp | 2 +- indra/newview/llwatchdog.cpp | 23 +- indra/newview/llwatchdog.h | 8 +- indra/newview/llwindebug.cpp | 66 ++- indra/newview/llwindebug.h | 3 +- indra/newview/pipeline.cpp | 42 +- indra/newview/pipeline.h | 2 +- .../newview/skins/default/xui/da/floater_about.xml | 35 ++ .../skins/default/xui/da/floater_about_land.xml | 431 ++++++++++++++ .../default/xui/da/floater_animation_preview.xml | 172 ++++++ .../skins/default/xui/da/floater_auction.xml | 9 + .../skins/default/xui/da/floater_avatar_picker.xml | 15 + .../default/xui/da/floater_avatar_textures.xml | 30 + .../skins/default/xui/da/floater_beacons.xml | 16 + .../skins/default/xui/da/floater_build_options.xml | 8 + .../newview/skins/default/xui/da/floater_bumps.xml | 21 + .../skins/default/xui/da/floater_buy_contents.xml | 21 + .../skins/default/xui/da/floater_buy_currency.xml | 66 +++ .../skins/default/xui/da/floater_buy_land.xml | 229 ++++++++ .../skins/default/xui/da/floater_buy_object.xml | 26 + .../skins/default/xui/da/floater_camera.xml | 12 + .../skins/default/xui/da/floater_choose_group.xml | 8 + .../skins/default/xui/da/floater_color_picker.xml | 31 + .../skins/default/xui/da/floater_critical.xml | 11 + .../skins/default/xui/da/floater_customize.xml | 455 +++++++++++++++ .../default/xui/da/floater_day_cycle_options.xml | 64 +++ .../default/xui/da/floater_device_settings.xml | 2 + .../skins/default/xui/da/floater_inventory.xml | 47 ++ .../xui/da/floater_inventory_item_properties.xml | 85 +++ .../skins/default/xui/da/floater_joystick.xml | 88 +++ .../skins/default/xui/da/floater_lagmeter.xml | 153 +++++ .../skins/default/xui/da/floater_land_holdings.xml | 41 ++ .../default/xui/da/floater_live_lsleditor.xml | 12 + .../skins/default/xui/da/floater_lsl_guide.xml | 7 + .../skins/default/xui/da/floater_media_browser.xml | 19 + .../skins/default/xui/da/floater_moveview.xml | 11 + .../skins/default/xui/da/floater_mute_object.xml | 12 + .../skins/default/xui/da/floater_my_friends.xml | 7 + .../skins/default/xui/da/floater_openobject.xml | 10 + indra/newview/skins/default/xui/da/floater_pay.xml | 21 + .../skins/default/xui/da/floater_pay_object.xml | 30 + .../skins/default/xui/da/floater_postcard.xml | 36 ++ .../skins/default/xui/da/floater_preferences.xml | 8 + .../default/xui/da/floater_preview_animation.xml | 10 + .../default/xui/da/floater_preview_classified.xml | 2 + .../skins/default/xui/da/floater_preview_event.xml | 2 + .../default/xui/da/floater_preview_gesture.xml | 57 ++ .../default/xui/da/floater_preview_notecard.xml | 16 + .../skins/default/xui/da/floater_preview_sound.xml | 10 + .../default/xui/da/floater_preview_texture.xml | 9 + .../skins/default/xui/da/floater_report_abuse.xml | 180 ++++++ .../skins/default/xui/da/floater_script_debug.xml | 6 + .../default/xui/da/floater_script_preview.xml | 6 + .../skins/default/xui/da/floater_script_queue.xml | 4 + .../skins/default/xui/da/floater_script_search.xml | 13 + .../skins/default/xui/da/floater_select_key.xml | 7 + .../skins/default/xui/da/floater_sell_land.xml | 68 +++ .../default/xui/da/floater_settings_debug.xml | 17 + .../skins/default/xui/da/floater_snapshot.xml | 137 +++++ .../skins/default/xui/da/floater_sound_preview.xml | 11 + .../skins/default/xui/da/floater_telehub.xml | 28 + .../skins/default/xui/da/floater_texture_ctrl.xml | 24 + .../newview/skins/default/xui/da/floater_tools.xml | 224 ++++++++ indra/newview/skins/default/xui/da/floater_tos.xml | 15 + .../default/xui/da/floater_wearable_save_as.xml | 11 + .../skins/default/xui/da/floater_world_map.xml | 86 +++ .../skins/default/xui/da/menu_inventory.xml | 65 +++ indra/newview/skins/default/xui/da/menu_login.xml | 13 + indra/newview/skins/default/xui/da/menu_slurl.xml | 6 + indra/newview/skins/default/xui/da/menu_viewer.xml | 199 +++++++ indra/newview/skins/default/xui/da/panel_login.xml | 37 ++ .../default/xui/da/panel_preferences_chat.xml | 57 ++ .../default/xui/da/panel_preferences_general.xml | 108 ++++ .../default/xui/da/panel_preferences_graphics1.xml | 179 ++++++ indra/newview/skins/default/xui/da/strings.xml | 26 + indra/newview/skins/default/xui/da/xui_version.xml | 4 + .../skins/default/xui/de/floater_about_land.xml | 445 ++++++-------- .../default/xui/de/floater_animation_preview.xml | 92 ++- .../skins/default/xui/de/floater_avatar_picker.xml | 2 +- .../default/xui/de/floater_avatar_textures.xml | 12 +- .../skins/default/xui/de/floater_buy_contents.xml | 4 +- .../skins/default/xui/de/floater_buy_land.xml | 6 +- .../skins/default/xui/de/floater_buy_object.xml | 2 +- .../skins/default/xui/de/floater_color_picker.xml | 4 +- .../skins/default/xui/de/floater_customize.xml | 2 +- .../skins/default/xui/de/floater_env_settings.xml | 2 +- .../skins/default/xui/de/floater_god_tools.xml | 52 +- .../skins/default/xui/de/floater_inspect.xml | 2 +- .../xui/de/floater_inventory_item_properties.xml | 2 +- .../skins/default/xui/de/floater_lagmeter.xml | 2 +- .../skins/default/xui/de/floater_land_holdings.xml | 8 +- .../skins/default/xui/de/floater_lsl_guide.xml | 2 +- .../skins/default/xui/de/floater_openobject.xml | 4 +- .../skins/default/xui/de/floater_pay_object.xml | 22 +- .../default/xui/de/floater_preview_animation.xml | 5 +- .../default/xui/de/floater_preview_gesture.xml | 6 +- .../skins/default/xui/de/floater_report_abuse.xml | 63 +- .../skins/default/xui/de/floater_script_queue.xml | 2 +- .../default/xui/de/floater_settings_debug.xml | 2 +- .../skins/default/xui/de/floater_telehub.xml | 26 +- .../newview/skins/default/xui/de/floater_tools.xml | 23 +- .../skins/default/xui/de/floater_top_objects.xml | 80 ++- .../skins/default/xui/de/floater_url_entry.xml | 3 +- .../newview/skins/default/xui/de/floater_water.xml | 7 +- .../skins/default/xui/de/floater_world_map.xml | 67 +-- indra/newview/skins/default/xui/de/menu_viewer.xml | 418 ++++++-------- indra/newview/skins/default/xui/de/mime_types.xml | 4 +- .../newview/skins/default/xui/de/panel_friends.xml | 2 +- .../skins/default/xui/de/panel_group_general.xml | 71 +-- .../skins/default/xui/de/panel_group_invite.xml | 2 +- .../default/xui/de/panel_group_land_money.xml | 2 +- .../skins/default/xui/de/panel_group_notices.xml | 6 +- .../skins/default/xui/de/panel_group_roles.xml | 95 ++- .../default/xui/de/panel_preferences_general.xml | 114 ++-- .../skins/default/xui/de/panel_region_debug.xml | 65 +-- .../skins/default/xui/de/panel_region_estate.xml | 3 +- .../skins/default/xui/de/panel_status_bar.xml | 43 +- .../skins/default/xui/es/floater_about_land.xml | 21 - indra/newview/skins/default/xui/es/menu_viewer.xml | 2 +- .../newview/skins/default/xui/fr/floater_about.xml | 4 +- .../skins/default/xui/fr/floater_about_land.xml | 441 ++++++-------- .../default/xui/fr/floater_animation_preview.xml | 47 +- .../skins/default/xui/fr/floater_avatar_picker.xml | 10 +- .../skins/default/xui/fr/floater_buy_contents.xml | 10 +- .../skins/default/xui/fr/floater_buy_currency.xml | 26 +- .../skins/default/xui/fr/floater_buy_land.xml | 66 +-- .../skins/default/xui/fr/floater_buy_object.xml | 8 +- .../skins/default/xui/fr/floater_color_picker.xml | 16 +- .../skins/default/xui/fr/floater_customize.xml | 544 ++++++++---------- .../skins/default/xui/fr/floater_env_settings.xml | 20 +- .../skins/default/xui/fr/floater_god_tools.xml | 133 ++--- .../default/xui/fr/floater_hardware_settings.xml | 20 +- .../skins/default/xui/fr/floater_image_preview.xml | 12 +- .../skins/default/xui/fr/floater_inventory.xml | 74 +-- .../xui/fr/floater_inventory_item_properties.xml | 31 +- .../xui/fr/floater_inventory_view_finder.xml | 40 +- .../skins/default/xui/fr/floater_joystick.xml | 4 +- .../skins/default/xui/fr/floater_lagmeter.xml | 18 +- .../skins/default/xui/fr/floater_lsl_guide.xml | 4 +- .../skins/default/xui/fr/floater_media_browser.xml | 22 +- .../skins/default/xui/fr/floater_moveview.xml | 23 +- .../skins/default/xui/fr/floater_mute_object.xml | 10 +- .../skins/default/xui/fr/floater_openobject.xml | 7 +- indra/newview/skins/default/xui/fr/floater_pay.xml | 24 +- .../skins/default/xui/fr/floater_pay_object.xml | 29 +- .../skins/default/xui/fr/floater_preferences.xml | 3 +- .../default/xui/fr/floater_preview_animation.xml | 4 +- .../default/xui/fr/floater_preview_gesture.xml | 6 +- .../default/xui/fr/floater_preview_notecard.xml | 2 +- .../skins/default/xui/fr/floater_preview_sound.xml | 2 +- .../skins/default/xui/fr/floater_region_info.xml | 4 +- .../skins/default/xui/fr/floater_report_abuse.xml | 69 ++- .../skins/default/xui/fr/floater_sell_land.xml | 42 +- .../default/xui/fr/floater_settings_debug.xml | 2 +- .../skins/default/xui/fr/floater_snapshot.xml | 42 +- .../skins/default/xui/fr/floater_sound_preview.xml | 6 +- .../skins/default/xui/fr/floater_telehub.xml | 23 +- .../skins/default/xui/fr/floater_texture_ctrl.xml | 24 +- .../newview/skins/default/xui/fr/floater_tools.xml | 371 ++++++------ .../skins/default/xui/fr/floater_top_objects.xml | 64 ++- .../skins/default/xui/fr/floater_url_entry.xml | 3 +- .../default/xui/fr/floater_windlight_options.xml | 4 +- .../skins/default/xui/fr/floater_world_map.xml | 95 ++- .../skins/default/xui/fr/menu_inventory.xml | 125 ++-- indra/newview/skins/default/xui/fr/menu_viewer.xml | 442 ++++++-------- indra/newview/skins/default/xui/fr/mime_types.xml | 8 +- .../skins/default/xui/fr/panel_audio_device.xml | 9 +- .../newview/skins/default/xui/fr/panel_friends.xml | 37 +- .../skins/default/xui/fr/panel_group_general.xml | 74 +-- .../skins/default/xui/fr/panel_group_invite.xml | 27 +- .../default/xui/fr/panel_group_land_money.xml | 43 +- .../skins/default/xui/fr/panel_group_notices.xml | 75 ++- .../skins/default/xui/fr/panel_group_roles.xml | 104 ++-- .../newview/skins/default/xui/fr/panel_groups.xml | 26 +- indra/newview/skins/default/xui/fr/panel_login.xml | 16 +- .../default/xui/fr/panel_preferences_chat.xml | 73 ++- .../default/xui/fr/panel_preferences_general.xml | 132 ++--- .../default/xui/fr/panel_preferences_graphics1.xml | 94 ++- .../skins/default/xui/fr/panel_region_covenant.xml | 13 +- .../skins/default/xui/fr/panel_region_debug.xml | 69 +-- .../skins/default/xui/fr/panel_region_estate.xml | 84 +-- .../skins/default/xui/fr/panel_region_general.xml | 55 +- .../skins/default/xui/fr/panel_region_terrain.xml | 41 +- .../skins/default/xui/fr/panel_scrolling_param.xml | 4 +- .../skins/default/xui/fr/panel_status_bar.xml | 44 +- .../newview/skins/default/xui/fr/role_actions.xml | 172 +++--- indra/newview/skins/default/xui/fr/strings.xml | 16 +- .../newview/skins/default/xui/ja/floater_about.xml | 2 +- .../skins/default/xui/ja/floater_about_land.xml | 450 ++++++--------- .../default/xui/ja/floater_avatar_textures.xml | 12 +- .../skins/default/xui/ja/floater_buy_currency.xml | 6 +- .../skins/default/xui/ja/floater_customize.xml | 2 +- .../default/xui/ja/floater_hardware_settings.xml | 4 +- indra/newview/skins/default/xui/ja/floater_im.xml | 2 +- .../skins/default/xui/ja/floater_inspect.xml | 2 +- .../skins/default/xui/ja/floater_media_browser.xml | 2 +- .../skins/default/xui/ja/floater_mute_object.xml | 8 +- .../skins/default/xui/ja/floater_postcard.xml | 12 +- .../default/xui/ja/floater_preview_gesture.xml | 6 +- .../skins/default/xui/ja/floater_report_abuse.xml | 60 +- .../skins/default/xui/ja/floater_snapshot.xml | 22 +- .../newview/skins/default/xui/ja/floater_tools.xml | 34 +- .../skins/default/xui/ja/floater_url_entry.xml | 6 +- indra/newview/skins/default/xui/ja/menu_viewer.xml | 430 ++++++-------- .../newview/skins/default/xui/ja/panel_groups.xml | 8 +- indra/newview/skins/default/xui/ja/panel_login.xml | 18 +- .../default/xui/ja/panel_preferences_chat.xml | 8 +- .../default/xui/ja/panel_preferences_general.xml | 109 ++-- .../default/xui/ja/panel_preferences_graphics1.xml | 2 +- .../skins/default/xui/ja/panel_region_debug.xml | 67 +-- .../skins/default/xui/ja/panel_region_estate.xml | 3 +- .../skins/default/xui/ja/panel_region_general.xml | 12 +- .../skins/default/xui/ja/panel_status_bar.xml | 43 +- .../newview/skins/default/xui/pl/floater_about.xml | 37 ++ .../skins/default/xui/pl/floater_about_land.xml | 431 ++++++++++++++ .../default/xui/pl/floater_animation_preview.xml | 172 ++++++ .../skins/default/xui/pl/floater_auction.xml | 9 + .../skins/default/xui/pl/floater_avatar_picker.xml | 15 + .../default/xui/pl/floater_avatar_textures.xml | 30 + .../skins/default/xui/pl/floater_beacons.xml | 15 + .../skins/default/xui/pl/floater_build_options.xml | 8 + .../newview/skins/default/xui/pl/floater_bumps.xml | 21 + .../skins/default/xui/pl/floater_buy_contents.xml | 21 + .../skins/default/xui/pl/floater_buy_currency.xml | 68 +++ .../skins/default/xui/pl/floater_buy_land.xml | 227 ++++++++ .../skins/default/xui/pl/floater_buy_object.xml | 26 + .../skins/default/xui/pl/floater_camera.xml | 12 + .../skins/default/xui/pl/floater_choose_group.xml | 8 + .../skins/default/xui/pl/floater_color_picker.xml | 31 + .../skins/default/xui/pl/floater_critical.xml | 11 + .../skins/default/xui/pl/floater_customize.xml | 457 +++++++++++++++ .../default/xui/pl/floater_day_cycle_options.xml | 99 ++++ .../default/xui/pl/floater_device_settings.xml | 3 + .../skins/default/xui/pl/floater_env_settings.xml | 26 + .../skins/default/xui/pl/floater_gesture.xml | 16 + .../skins/default/xui/pl/floater_god_tools.xml | 113 ++++ .../default/xui/pl/floater_hardware_settings.xml | 38 ++ indra/newview/skins/default/xui/pl/floater_hud.xml | 2 + indra/newview/skins/default/xui/pl/floater_im.xml | 45 ++ .../skins/default/xui/pl/floater_image_preview.xml | 52 ++ .../skins/default/xui/pl/floater_inspect.xml | 13 + .../skins/default/xui/pl/floater_inventory.xml | 47 ++ .../xui/pl/floater_inventory_item_properties.xml | 85 +++ .../xui/pl/floater_inventory_view_finder.xml | 24 + .../skins/default/xui/pl/floater_joystick.xml | 124 ++++ .../skins/default/xui/pl/floater_lagmeter.xml | 154 +++++ .../skins/default/xui/pl/floater_land_holdings.xml | 41 ++ .../default/xui/pl/floater_live_lsleditor.xml | 12 + .../skins/default/xui/pl/floater_lsl_guide.xml | 7 + .../skins/default/xui/pl/floater_media_browser.xml | 19 + .../skins/default/xui/pl/floater_mem_leaking.xml | 18 + .../skins/default/xui/pl/floater_moveview.xml | 13 + .../skins/default/xui/pl/floater_mute_object.xml | 12 + .../skins/default/xui/pl/floater_my_friends.xml | 7 + .../skins/default/xui/pl/floater_openobject.xml | 10 + indra/newview/skins/default/xui/pl/floater_pay.xml | 21 + .../skins/default/xui/pl/floater_pay_object.xml | 30 + .../skins/default/xui/pl/floater_post_process.xml | 62 ++ .../skins/default/xui/pl/floater_postcard.xml | 36 ++ .../skins/default/xui/pl/floater_preferences.xml | 8 + .../default/xui/pl/floater_preview_animation.xml | 10 + .../default/xui/pl/floater_preview_classified.xml | 2 + .../skins/default/xui/pl/floater_preview_event.xml | 2 + .../default/xui/pl/floater_preview_gesture.xml | 57 ++ .../default/xui/pl/floater_preview_notecard.xml | 16 + .../skins/default/xui/pl/floater_preview_sound.xml | 12 + .../default/xui/pl/floater_preview_texture.xml | 9 + .../skins/default/xui/pl/floater_region_info.xml | 2 + .../skins/default/xui/pl/floater_report_abuse.xml | 184 ++++++ .../skins/default/xui/pl/floater_script_debug.xml | 6 + .../default/xui/pl/floater_script_preview.xml | 6 + .../skins/default/xui/pl/floater_script_queue.xml | 4 + .../skins/default/xui/pl/floater_script_search.xml | 14 + .../skins/default/xui/pl/floater_select_key.xml | 7 + .../skins/default/xui/pl/floater_sell_land.xml | 68 +++ .../default/xui/pl/floater_settings_debug.xml | 17 + .../skins/default/xui/pl/floater_snapshot.xml | 137 +++++ .../skins/default/xui/pl/floater_sound_preview.xml | 11 + .../skins/default/xui/pl/floater_telehub.xml | 28 + .../skins/default/xui/pl/floater_texture_ctrl.xml | 24 + .../newview/skins/default/xui/pl/floater_tools.xml | 636 +++++++++++++++++++++ .../skins/default/xui/pl/floater_top_objects.xml | 51 ++ indra/newview/skins/default/xui/pl/floater_tos.xml | 16 + .../skins/default/xui/pl/floater_url_entry.xml | 12 + .../newview/skins/default/xui/pl/floater_water.xml | 103 ++++ .../default/xui/pl/floater_wearable_save_as.xml | 11 + .../default/xui/pl/floater_windlight_options.xml | 229 ++++++++ .../skins/default/xui/pl/floater_world_map.xml | 83 +++ .../skins/default/xui/pl/menu_inventory.xml | 65 +++ indra/newview/skins/default/xui/pl/menu_login.xml | 13 + indra/newview/skins/default/xui/pl/menu_slurl.xml | 6 + indra/newview/skins/default/xui/pl/menu_viewer.xml | 201 +++++++ indra/newview/skins/default/xui/pl/mime_types.xml | 230 ++++++++ .../skins/default/xui/pl/panel_audio_device.xml | 26 + .../newview/skins/default/xui/pl/panel_friends.xml | 27 + .../skins/default/xui/pl/panel_group_general.xml | 86 +++ .../skins/default/xui/pl/panel_group_invite.xml | 21 + .../default/xui/pl/panel_group_land_money.xml | 88 +++ .../skins/default/xui/pl/panel_group_notices.xml | 71 +++ .../skins/default/xui/pl/panel_group_roles.xml | 157 +++++ .../newview/skins/default/xui/pl/panel_groups.xml | 18 + indra/newview/skins/default/xui/pl/panel_login.xml | 43 ++ .../default/xui/pl/panel_preferences_chat.xml | 61 ++ .../default/xui/pl/panel_preferences_general.xml | 109 ++++ .../default/xui/pl/panel_preferences_graphics1.xml | 179 ++++++ .../skins/default/xui/pl/panel_region_covenant.xml | 50 ++ .../skins/default/xui/pl/panel_region_debug.xml | 40 ++ .../skins/default/xui/pl/panel_region_estate.xml | 74 +++ .../skins/default/xui/pl/panel_region_general.xml | 51 ++ .../skins/default/xui/pl/panel_region_terrain.xml | 30 + .../skins/default/xui/pl/panel_region_texture.xml | 57 ++ .../skins/default/xui/pl/panel_scrolling_param.xml | 12 + .../skins/default/xui/pl/panel_status_bar.xml | 43 ++ .../newview/skins/default/xui/pl/role_actions.xml | 197 +++++++ indra/newview/skins/default/xui/pl/strings.xml | 439 ++++++++++++++ .../skins/default/xui/pl/teleport_strings.xml | 80 +++ indra/newview/skins/default/xui/pl/xui_version.xml | 4 + .../newview/skins/default/xui/pt/floater_about.xml | 6 +- .../skins/default/xui/pt/floater_about_land.xml | 427 ++++++++------ .../default/xui/pt/floater_animation_preview.xml | 83 +-- .../skins/default/xui/pt/floater_avatar_picker.xml | 16 +- .../default/xui/pt/floater_avatar_textures.xml | 52 +- .../skins/default/xui/pt/floater_build_options.xml | 11 +- .../skins/default/xui/pt/floater_buy_contents.xml | 17 +- .../skins/default/xui/pt/floater_buy_currency.xml | 70 ++- .../skins/default/xui/pt/floater_buy_land.xml | 177 +++--- .../skins/default/xui/pt/floater_buy_object.xml | 21 +- .../skins/default/xui/pt/floater_customize.xml | 428 +++++++------- .../skins/default/xui/pt/floater_gesture.xml | 15 +- indra/newview/skins/default/xui/pt/floater_im.xml | 52 +- .../skins/default/xui/pt/floater_image_preview.xml | 7 +- .../skins/default/xui/pt/floater_inventory.xml | 64 +-- .../xui/pt/floater_inventory_item_properties.xml | 36 +- .../skins/default/xui/pt/floater_joystick.xml | 85 ++- .../skins/default/xui/pt/floater_land_holdings.xml | 29 +- .../default/xui/pt/floater_live_lsleditor.xml | 13 +- .../skins/default/xui/pt/floater_postcard.xml | 28 +- .../default/xui/pt/floater_preview_gesture.xml | 40 +- .../default/xui/pt/floater_preview_notecard.xml | 14 +- .../skins/default/xui/pt/floater_report_abuse.xml | 160 +++++- .../skins/default/xui/pt/floater_script_debug.xml | 8 +- .../skins/default/xui/pt/floater_snapshot.xml | 78 ++- .../skins/default/xui/pt/floater_texture_ctrl.xml | 31 +- .../newview/skins/default/xui/pt/floater_tools.xml | 403 +++++++------ .../skins/default/xui/pt/floater_top_objects.xml | 55 +- indra/newview/skins/default/xui/pt/floater_tos.xml | 21 +- .../skins/default/xui/pt/floater_world_map.xml | 9 +- .../skins/default/xui/pt/menu_inventory.xml | 4 +- indra/newview/skins/default/xui/pt/menu_viewer.xml | 356 ++++++------ .../skins/default/xui/pt/panel_group_general.xml | 88 +-- .../skins/default/xui/pt/panel_group_invite.xml | 27 +- .../default/xui/pt/panel_group_land_money.xml | 60 +- .../skins/default/xui/pt/panel_group_notices.xml | 4 +- .../skins/default/xui/pt/panel_group_roles.xml | 94 ++- indra/newview/skins/default/xui/pt/panel_login.xml | 20 +- .../default/xui/pt/panel_preferences_chat.xml | 69 +-- .../default/xui/pt/panel_preferences_general.xml | 118 ++-- .../default/xui/pt/panel_preferences_graphics1.xml | 184 +++++- .../skins/default/xui/pt/panel_region_covenant.xml | 14 +- .../skins/default/xui/pt/panel_region_debug.xml | 58 +- .../skins/default/xui/pt/panel_region_estate.xml | 80 +-- .../skins/default/xui/pt/panel_region_general.xml | 55 +- .../skins/default/xui/pt/panel_status_bar.xml | 46 +- .../skins/default/xui/pt/teleport_strings.xml | 43 +- indra/newview/viewer_manifest.py | 1 + indra/win_crash_logger/llcrashloggerwindows.cpp | 2 +- indra/win_crash_logger/win_crash_logger.cpp | 49 +- 433 files changed, 17411 insertions(+), 6507 deletions(-) create mode 100644 indra/newview/skins/default/xui/da/floater_about.xml create mode 100644 indra/newview/skins/default/xui/da/floater_about_land.xml create mode 100644 indra/newview/skins/default/xui/da/floater_animation_preview.xml create mode 100644 indra/newview/skins/default/xui/da/floater_auction.xml create mode 100644 indra/newview/skins/default/xui/da/floater_avatar_picker.xml create mode 100644 indra/newview/skins/default/xui/da/floater_avatar_textures.xml create mode 100644 indra/newview/skins/default/xui/da/floater_beacons.xml create mode 100644 indra/newview/skins/default/xui/da/floater_build_options.xml create mode 100644 indra/newview/skins/default/xui/da/floater_bumps.xml create mode 100644 indra/newview/skins/default/xui/da/floater_buy_contents.xml create mode 100644 indra/newview/skins/default/xui/da/floater_buy_currency.xml create mode 100644 indra/newview/skins/default/xui/da/floater_buy_land.xml create mode 100644 indra/newview/skins/default/xui/da/floater_buy_object.xml create mode 100644 indra/newview/skins/default/xui/da/floater_camera.xml create mode 100644 indra/newview/skins/default/xui/da/floater_choose_group.xml create mode 100644 indra/newview/skins/default/xui/da/floater_color_picker.xml create mode 100644 indra/newview/skins/default/xui/da/floater_critical.xml create mode 100644 indra/newview/skins/default/xui/da/floater_customize.xml create mode 100644 indra/newview/skins/default/xui/da/floater_day_cycle_options.xml create mode 100644 indra/newview/skins/default/xui/da/floater_device_settings.xml create mode 100644 indra/newview/skins/default/xui/da/floater_inventory.xml create mode 100644 indra/newview/skins/default/xui/da/floater_inventory_item_properties.xml create mode 100644 indra/newview/skins/default/xui/da/floater_joystick.xml create mode 100644 indra/newview/skins/default/xui/da/floater_lagmeter.xml create mode 100644 indra/newview/skins/default/xui/da/floater_land_holdings.xml create mode 100644 indra/newview/skins/default/xui/da/floater_live_lsleditor.xml create mode 100644 indra/newview/skins/default/xui/da/floater_lsl_guide.xml create mode 100644 indra/newview/skins/default/xui/da/floater_media_browser.xml create mode 100644 indra/newview/skins/default/xui/da/floater_moveview.xml create mode 100644 indra/newview/skins/default/xui/da/floater_mute_object.xml create mode 100644 indra/newview/skins/default/xui/da/floater_my_friends.xml create mode 100644 indra/newview/skins/default/xui/da/floater_openobject.xml create mode 100644 indra/newview/skins/default/xui/da/floater_pay.xml create mode 100644 indra/newview/skins/default/xui/da/floater_pay_object.xml create mode 100644 indra/newview/skins/default/xui/da/floater_postcard.xml create mode 100644 indra/newview/skins/default/xui/da/floater_preferences.xml create mode 100644 indra/newview/skins/default/xui/da/floater_preview_animation.xml create mode 100644 indra/newview/skins/default/xui/da/floater_preview_classified.xml create mode 100644 indra/newview/skins/default/xui/da/floater_preview_event.xml create mode 100644 indra/newview/skins/default/xui/da/floater_preview_gesture.xml create mode 100644 indra/newview/skins/default/xui/da/floater_preview_notecard.xml create mode 100644 indra/newview/skins/default/xui/da/floater_preview_sound.xml create mode 100644 indra/newview/skins/default/xui/da/floater_preview_texture.xml create mode 100644 indra/newview/skins/default/xui/da/floater_report_abuse.xml create mode 100644 indra/newview/skins/default/xui/da/floater_script_debug.xml create mode 100644 indra/newview/skins/default/xui/da/floater_script_preview.xml create mode 100644 indra/newview/skins/default/xui/da/floater_script_queue.xml create mode 100644 indra/newview/skins/default/xui/da/floater_script_search.xml create mode 100644 indra/newview/skins/default/xui/da/floater_select_key.xml create mode 100644 indra/newview/skins/default/xui/da/floater_sell_land.xml create mode 100644 indra/newview/skins/default/xui/da/floater_settings_debug.xml create mode 100644 indra/newview/skins/default/xui/da/floater_snapshot.xml create mode 100644 indra/newview/skins/default/xui/da/floater_sound_preview.xml create mode 100644 indra/newview/skins/default/xui/da/floater_telehub.xml create mode 100644 indra/newview/skins/default/xui/da/floater_texture_ctrl.xml create mode 100644 indra/newview/skins/default/xui/da/floater_tools.xml create mode 100644 indra/newview/skins/default/xui/da/floater_tos.xml create mode 100644 indra/newview/skins/default/xui/da/floater_wearable_save_as.xml create mode 100644 indra/newview/skins/default/xui/da/floater_world_map.xml create mode 100644 indra/newview/skins/default/xui/da/menu_inventory.xml create mode 100644 indra/newview/skins/default/xui/da/menu_login.xml create mode 100644 indra/newview/skins/default/xui/da/menu_slurl.xml create mode 100644 indra/newview/skins/default/xui/da/menu_viewer.xml create mode 100644 indra/newview/skins/default/xui/da/panel_login.xml create mode 100644 indra/newview/skins/default/xui/da/panel_preferences_chat.xml create mode 100644 indra/newview/skins/default/xui/da/panel_preferences_general.xml create mode 100644 indra/newview/skins/default/xui/da/panel_preferences_graphics1.xml create mode 100644 indra/newview/skins/default/xui/da/strings.xml create mode 100644 indra/newview/skins/default/xui/da/xui_version.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_about.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_about_land.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_animation_preview.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_auction.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_avatar_picker.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_avatar_textures.xml create mode 100644 indra/newview/skins/default/xui/pl/floater_beacons.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_build_options.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_bumps.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_buy_contents.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_buy_currency.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_buy_land.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_buy_object.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_camera.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_choose_group.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_color_picker.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_critical.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_customize.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_day_cycle_options.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_device_settings.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_env_settings.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_gesture.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_god_tools.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_hardware_settings.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_hud.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_im.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_image_preview.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_inspect.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_inventory.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_inventory_item_properties.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_inventory_view_finder.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_joystick.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_lagmeter.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_land_holdings.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_live_lsleditor.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_lsl_guide.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_media_browser.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_mem_leaking.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_moveview.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_mute_object.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_my_friends.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_openobject.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_pay.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_pay_object.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_post_process.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_postcard.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_preferences.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_preview_animation.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_preview_classified.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_preview_event.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_preview_gesture.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_preview_notecard.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_preview_sound.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_preview_texture.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_region_info.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_report_abuse.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_script_debug.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_script_preview.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_script_queue.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_script_search.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_select_key.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_sell_land.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_settings_debug.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_snapshot.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_sound_preview.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_telehub.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_texture_ctrl.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_tools.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_top_objects.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_tos.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_url_entry.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_water.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_wearable_save_as.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_windlight_options.xml create mode 100755 indra/newview/skins/default/xui/pl/floater_world_map.xml create mode 100755 indra/newview/skins/default/xui/pl/menu_inventory.xml create mode 100755 indra/newview/skins/default/xui/pl/menu_login.xml create mode 100755 indra/newview/skins/default/xui/pl/menu_slurl.xml create mode 100755 indra/newview/skins/default/xui/pl/menu_viewer.xml create mode 100755 indra/newview/skins/default/xui/pl/mime_types.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_audio_device.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_friends.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_group_general.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_group_invite.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_group_land_money.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_group_notices.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_group_roles.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_groups.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_login.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_preferences_chat.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_preferences_general.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_preferences_graphics1.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_region_covenant.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_region_debug.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_region_estate.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_region_general.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_region_terrain.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_region_texture.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_scrolling_param.xml create mode 100755 indra/newview/skins/default/xui/pl/panel_status_bar.xml create mode 100755 indra/newview/skins/default/xui/pl/role_actions.xml create mode 100755 indra/newview/skins/default/xui/pl/strings.xml create mode 100755 indra/newview/skins/default/xui/pl/teleport_strings.xml create mode 100755 indra/newview/skins/default/xui/pl/xui_version.xml (limited to 'indra') diff --git a/indra/develop.py b/indra/develop.py index a1eeff0e01..64a0ecfbd8 100755 --- a/indra/develop.py +++ b/indra/develop.py @@ -593,7 +593,7 @@ class WindowsSetup(PlatformSetup): class CygwinSetup(WindowsSetup): def __init__(self): super(CygwinSetup, self).__init__() - self.generator = 'vc71' + self.generator = 'vc80' def cmake_commandline(self, src_dir, build_dir, opts, simple): dos_dir = commands.getoutput("cygpath -w %s" % src_dir) diff --git a/indra/lib/python/indra/util/llmanifest.py b/indra/lib/python/indra/util/llmanifest.py index 467517756a..a00d242e49 100644 --- a/indra/lib/python/indra/util/llmanifest.py +++ b/indra/lib/python/indra/util/llmanifest.py @@ -584,7 +584,7 @@ class LLManifest(object): def wildcard_regex(self, src_glob, dst_glob): src_re = re.escape(src_glob) - src_re = src_re.replace('\*', '([-a-zA-Z0-9._ ]+)') + src_re = src_re.replace('\*', '([-a-zA-Z0-9._ ]*)') dst_temp = dst_glob i = 1 while dst_temp.count("*") > 0: @@ -621,6 +621,7 @@ class LLManifest(object): count = 0 if self.wildcard_pattern.search(src): for s,d in self.expand_globs(src, dst): + assert(s != d) count += self.process_file(s, d) else: # if we're specifying a single path (not a glob), diff --git a/indra/linux_crash_logger/CMakeLists.txt b/indra/linux_crash_logger/CMakeLists.txt index d03487b01b..6f6754ed7a 100644 --- a/indra/linux_crash_logger/CMakeLists.txt +++ b/indra/linux_crash_logger/CMakeLists.txt @@ -57,10 +57,9 @@ target_link_libraries(linux-crash-logger add_custom_command( OUTPUT linux-crash-logger-stripped COMMAND strip - ARGS --strip-debug -o linux-crash-logger-stripped - linux-crash-logger + ARGS --strip-debug -o linux-crash-logger-stripped linux-crash-logger DEPENDS linux-crash-logger ) -add_custom_target(linux-crash-logger-stripped ALL +add_custom_target(linux-crash-logger-strip-target ALL DEPENDS linux-crash-logger-stripped) diff --git a/indra/llcharacter/lleditingmotion.cpp b/indra/llcharacter/lleditingmotion.cpp index 301a6e74c9..4421671854 100644 --- a/indra/llcharacter/lleditingmotion.cpp +++ b/indra/llcharacter/lleditingmotion.cpp @@ -190,7 +190,7 @@ BOOL LLEditingMotion::onUpdate(F32 time, U8* joint_mask) { LLVector3 tmp = mCharacter->getCharacterPosition() ; llerrs << "Non finite focus point in editing motion. focus point: " << focus_pt << " and character position: " << - tmp << " and pointAtPt: " << pointAtPt << llendl; + tmp << " and pointAtPt: " << *pointAtPt << llendl; } // propagate joint positions to kinematic chain @@ -226,7 +226,7 @@ BOOL LLEditingMotion::onUpdate(F32 time, U8* joint_mask) if (!target.isFinite()) { llerrs << "Non finite target in editing motion with target distance of " << target_dist << - " and focus point " << focus_pt << " and pointAtPt: " << pointAtPt << llendl; + " and focus point " << focus_pt << " and pointAtPt: " << *pointAtPt << llendl; } mTarget.setPosition( target + mParentJoint.getPosition()); diff --git a/indra/llcommon/llerror.cpp b/indra/llcommon/llerror.cpp index b3d3122397..a54785134c 100644 --- a/indra/llcommon/llerror.cpp +++ b/indra/llcommon/llerror.cpp @@ -1170,6 +1170,10 @@ namespace LLError return s.shouldLogCallCounter; } +#if LL_WINDOWS + // VC80 was optimizing the error away. + #pragma optimize("", off) +#endif void crashAndLoop(const std::string& message) { // Now, we go kaboom! @@ -1182,6 +1186,9 @@ namespace LLError // Loop forever, in case the crash didn't work? } } +#if LL_WINDOWS + #pragma optimize("", on) +#endif std::string utcTime() { diff --git a/indra/llcommon/llerrorcontrol.h b/indra/llcommon/llerrorcontrol.h index 528704d064..bab4af33e6 100644 --- a/indra/llcommon/llerrorcontrol.h +++ b/indra/llcommon/llerrorcontrol.h @@ -82,9 +82,9 @@ namespace LLError Control functions. */ - typedef void (*FatalFunction)(const std::string& message); + typedef void(*FatalFunction)(const std::string& message); void crashAndLoop(const std::string& message); - // Default fatal funtion: divides by zero and loops forever + // Default fatal funtion: access null pointer and loops forever void setFatalFunction(FatalFunction); // The fatal function will be called when an message of LEVEL_ERROR diff --git a/indra/llcommon/llversionviewer.h b/indra/llcommon/llversionviewer.h index 27d69c453d..814daa9029 100644 --- a/indra/llcommon/llversionviewer.h +++ b/indra/llcommon/llversionviewer.h @@ -34,8 +34,8 @@ const S32 LL_VERSION_MAJOR = 1; const S32 LL_VERSION_MINOR = 22; -const S32 LL_VERSION_PATCH = 0; -const S32 LL_VERSION_BUILD = 100000; +const S32 LL_VERSION_PATCH = 4; +const S32 LL_VERSION_BUILD = 0; const char * const LL_CHANNEL = "Second Life Release"; diff --git a/indra/llcrashlogger/llcrashlogger.cpp b/indra/llcrashlogger/llcrashlogger.cpp index 7f3c736669..5993e557f0 100755 --- a/indra/llcrashlogger/llcrashlogger.cpp +++ b/indra/llcrashlogger/llcrashlogger.cpp @@ -123,6 +123,33 @@ void trimSLLog(std::string& sllog) } } +std::string getStartupStateFromLog(std::string& sllog) +{ + std::string startup_state = "STATE_FIRST"; + std::string startup_token = "Startup state changing from "; + + int index = sllog.rfind(startup_token); + if (index < 0 || index + startup_token.length() > sllog.length()) { + return startup_state; + } + + // find new line + char cur_char = sllog[index + startup_token.length()]; + std::string::size_type newline_loc = index + startup_token.length(); + while(cur_char != '\n' && newline_loc < sllog.length()) + { + newline_loc++; + cur_char = sllog[newline_loc]; + } + + // get substring and find location of " to " + std::string state_line = sllog.substr(index, newline_loc - index); + std::string::size_type state_index = state_line.find(" to "); + startup_state = state_line.substr(state_index + 4, state_line.length() - state_index - 4); + + return startup_state; +} + void LLCrashLogger::gatherFiles() { @@ -154,6 +181,9 @@ void LLCrashLogger::gatherFiles() if (debug_log_file.is_open()) { LLSDSerialize::fromXML(mDebugLog, debug_log_file); + + mCrashInPreviousExec = mDebugLog["CrashNotHandled"].asBoolean(); + mFileMap["SecondLifeLog"] = mDebugLog["SLLog"].asString(); mFileMap["SettingsXml"] = mDebugLog["SettingsFilename"].asString(); if(mDebugLog.has("CAFilename")) @@ -176,6 +206,16 @@ void LLCrashLogger::gatherFiles() mFileMap["SettingsXml"] = gDirUtilp->getExpandedFilename(LL_PATH_USER_SETTINGS,"settings.xml"); } + if(mCrashInPreviousExec) + { + // Replace the log file ext with .old, since the + // instance that launched this process has overwritten + // SecondLife.log + std::string log_filename = mFileMap["SecondLifeLog"]; + log_filename.replace(log_filename.size() - 4, 4, ".old"); + mFileMap["SecondLifeLog"] = log_filename; + } + gatherPlatformSpecificFiles(); //Use the debug log to reconstruct the URL to send the crash report to @@ -219,6 +259,10 @@ void LLCrashLogger::gatherFiles() std::string crash_info = s.str(); if(itr->first == "SecondLifeLog") { + if(!mCrashInfo["DebugLog"].has("StartupState")) + { + mCrashInfo["DebugLog"]["StartupState"] = getStartupStateFromLog(crash_info); + } trimSLLog(crash_info); } @@ -229,12 +273,6 @@ void LLCrashLogger::gatherFiles() LLSD LLCrashLogger::constructPostData() { LLSD ret; - - if(mCrashInPreviousExec) - { - mCrashInfo["CrashInPreviousExecution"] = "Y"; - } - return mCrashInfo; } @@ -338,25 +376,6 @@ bool LLCrashLogger::init() llinfos << "Loading crash behavior setting" << llendl; mCrashBehavior = loadCrashBehaviorSetting(); - //Run through command line options - if(getOption("previous").isDefined()) - { - llinfos << "Previous execution did not remove SecondLife.exec_marker" << llendl; - mCrashInPreviousExec = TRUE; - } - - if(getOption("dialog").isDefined()) - { - llinfos << "Show the user dialog" << llendl; - mCrashBehavior = CRASH_BEHAVIOR_ASK; - } - - LLSD name = getOption("name"); - if(name.isDefined()) - { - mProductName = name.asString(); - } - // If user doesn't want to send, bail out if (mCrashBehavior == CRASH_BEHAVIOR_NEVER_SEND) { diff --git a/indra/llimage/llimagejpeg.cpp b/indra/llimage/llimagejpeg.cpp index aab19aa261..5f1c8275b4 100644 --- a/indra/llimage/llimagejpeg.cpp +++ b/indra/llimage/llimagejpeg.cpp @@ -465,7 +465,8 @@ void LLImageJPEG::errorOutputMessage( j_common_ptr cinfo ) char buffer[JMSG_LENGTH_MAX]; /* Flawfinder: ignore */ (*cinfo->err->format_message) (cinfo, buffer); - ((LLImageJPEG*) cinfo->client_data)->setLastError( buffer ); + std::string error = buffer ; + LLImage::setLastError(error); BOOL is_decode = (cinfo->is_decompressor != 0); llwarns << "LLImageJPEG " << (is_decode ? "decode " : "encode ") << " failed: " << buffer << llendl; diff --git a/indra/llmath/llvolume.cpp b/indra/llmath/llvolume.cpp index ba0cfa6ff5..8cdb43db46 100644 --- a/indra/llmath/llvolume.cpp +++ b/indra/llmath/llvolume.cpp @@ -1759,13 +1759,24 @@ BOOL LLVolume::generate() if (regenPath || regenProf ) { - sNumMeshPoints -= mMesh.size(); - mMesh.resize(mProfilep->mProfile.size() * mPathp->mPath.size()); - sNumMeshPoints += mMesh.size(); - S32 sizeS = mPathp->mPath.size(); S32 sizeT = mProfilep->mProfile.size(); + //debug info + if((U32)(sizeS * sizeT) > (1u << 20)) + { + llinfos << "regenPath: " << (S32)regenPath << " regenProf: " << (S32)regenProf << llendl ; + llinfos << "sizeS: " << sizeS << " sizeT: " << sizeT << llendl ; + llinfos << "path_detail : " << path_detail << " split: " << split << " profile_detail: " << profile_detail << llendl ; + llinfos << mParams << llendl ; + + llerrs << "LLVolume corrupted!" << llendl ; + } + + sNumMeshPoints -= mMesh.size(); + mMesh.resize(sizeT * sizeS); + sNumMeshPoints += mMesh.size(); + //generate vertex positions // Run along the path. diff --git a/indra/llrender/llgl.cpp b/indra/llrender/llgl.cpp index fa763bf2f8..aced88f1a2 100644 --- a/indra/llrender/llgl.cpp +++ b/indra/llrender/llgl.cpp @@ -263,7 +263,6 @@ LLGLManager::LLGLManager() : mHasMultitexture(FALSE), mNumTextureUnits(1), mHasMipMapGeneration(FALSE), - mHasPalettedTextures(FALSE), mHasCompressedTextures(FALSE), mHasFramebufferObject(FALSE), @@ -566,7 +565,6 @@ void LLGLManager::initExtensions() mHasFramebufferObject = FALSE; # endif mHasMipMapGeneration = FALSE; - mHasPalettedTextures = FALSE; mHasSeparateSpecularColor = FALSE; mHasAnisotropic = FALSE; mHasCubeMap = FALSE; @@ -578,7 +576,6 @@ void LLGLManager::initExtensions() #else // LL_MESA_HEADLESS mHasMultitexture = glh_init_extensions("GL_ARB_multitexture"); mHasMipMapGeneration = glh_init_extensions("GL_SGIS_generate_mipmap"); - mHasPalettedTextures = glh_init_extension("GL_EXT_paletted_texture"); mHasSeparateSpecularColor = glh_init_extensions("GL_EXT_separate_specular_color"); mHasAnisotropic = glh_init_extensions("GL_EXT_texture_filter_anisotropic"); glh_init_extensions("GL_ARB_texture_cube_map"); @@ -610,7 +607,6 @@ void LLGLManager::initExtensions() mHasVertexBufferObject = FALSE; mHasFramebufferObject = FALSE; mHasMipMapGeneration = FALSE; - mHasPalettedTextures = FALSE; mHasSeparateSpecularColor = FALSE; mHasAnisotropic = FALSE; mHasCubeMap = FALSE; @@ -628,7 +624,6 @@ void LLGLManager::initExtensions() // bug reports. This should be the default until we get a // proper blacklist/whitelist on Linux. mHasMipMapGeneration = FALSE; - mHasPalettedTextures = FALSE; mHasAnisotropic = FALSE; //mHasCubeMap = FALSE; // apparently fatal on Intel 915 & similar //mHasOcclusionQuery = FALSE; // source of many ATI system hangs @@ -648,7 +643,6 @@ void LLGLManager::initExtensions() if (strchr(blacklist,'b')) mHasCompressedTextures = FALSE; if (strchr(blacklist,'c')) mHasVertexBufferObject = FALSE; if (strchr(blacklist,'d')) mHasMipMapGeneration = FALSE;//S - if (strchr(blacklist,'e')) mHasPalettedTextures = FALSE;//S // if (strchr(blacklist,'f')) mHasNVVertexArrayRange = FALSE;//S // if (strchr(blacklist,'g')) mHasNVFence = FALSE;//S if (strchr(blacklist,'h')) mHasSeparateSpecularColor = FALSE; @@ -663,13 +657,6 @@ void LLGLManager::initExtensions() if (strchr(blacklist,'q')) mHasFramebufferObject = FALSE;//S } #endif // LL_LINUX - -#if LL_DARWIN || LL_LINUX - // MBW -- 12/4/2003 -- Using paletted textures causes a bunch of avatar rendering problems on the Mac. - // Not sure if this is due to driver problems or incorrect use of the extension, but I'm disabling it for now. - // Tofu - 2006-10-03 -- Same problem on Linux. - mHasPalettedTextures = false; -#endif if (!mHasMultitexture) { @@ -683,10 +670,6 @@ void LLGLManager::initExtensions() { LL_INFOS("RenderInit") << "Couldn't initialize GL_ARB_texture_env_combine" << LL_ENDL; } - if (!mHasPalettedTextures) - { - LL_INFOS("RenderInit") << "Couldn't initialize GL_EXT_paletted_texture" << LL_ENDL; - } if (!mHasSeparateSpecularColor) { LL_INFOS("RenderInit") << "Couldn't initialize separate specular color" << LL_ENDL; @@ -788,13 +771,7 @@ void LLGLManager::initExtensions() mGLMaxIndexRange = 0; } #endif // !LL_LINUX -#if LL_LINUX - // On Linux we need to get glColorTableEXT dynamically. - if (mHasPalettedTextures) - { - glColorTableEXT = (PFNGLCOLORTABLEEXTPROC)GLH_EXT_GET_PROC_ADDRESS("glColorTableEXT"); - } -#endif // LL_LINUX + if (mHasOcclusionQuery) { glGenQueriesARB = (PFNGLGENQUERIESARBPROC)GLH_EXT_GET_PROC_ADDRESS("glGenQueriesARB"); @@ -1442,16 +1419,6 @@ void set_binormals(const S32 index, const U32 stride,const LLVector3 *binormals) #endif } - -void set_palette(U8 *palette_data) -{ - if (gGLManager.mHasPalettedTextures) - { - glColorTableEXT(GL_TEXTURE_2D, GL_RGBA8, 256, GL_RGBA, GL_UNSIGNED_BYTE, palette_data); - } -} - - void parse_gl_version( S32* major, S32* minor, S32* release, std::string* vendor_specific ) { // GL_VERSION returns a null-terminated string with the format: diff --git a/indra/llrender/llgl.h b/indra/llrender/llgl.h index bab5e5245f..96a03e63ac 100644 --- a/indra/llrender/llgl.h +++ b/indra/llrender/llgl.h @@ -74,7 +74,6 @@ public: BOOL mHasMultitexture; S32 mNumTextureUnits; BOOL mHasMipMapGeneration; - BOOL mHasPalettedTextures; BOOL mHasCompressedTextures; BOOL mHasFramebufferObject; @@ -370,7 +369,6 @@ void disable_cloth_weights(const S32 index); void set_vertex_weights(const S32 index, const U32 stride, const F32 *weights); void set_vertex_clothing_weights(const S32 index, const U32 stride, const LLVector4 *weights); void set_binormals(const S32 index, const U32 stride, const LLVector3 *binormals); -void set_palette(U8* palette_data); void parse_gl_version( S32* major, S32* minor, S32* release, std::string* vendor_specific ); extern BOOL gClothRipple; diff --git a/indra/llrender/llimagegl.cpp b/indra/llrender/llimagegl.cpp index 2ef2bae1ab..9efadbd030 100644 --- a/indra/llrender/llimagegl.cpp +++ b/indra/llrender/llimagegl.cpp @@ -154,7 +154,7 @@ void LLImageGL::destroyGL(BOOL save_state) LLImageGL* glimage = *iter; if (glimage->mTexName && glimage->mComponents) { - if (save_state) + if (save_state && glimage->isInitialized()) { glimage->mSaveData = new LLImageRaw; glimage->readBackRaw(glimage->mCurrentDiscardLevel, glimage->mSaveData, false); @@ -748,7 +748,7 @@ BOOL LLImageGL::setSubImage(const LLImageRaw* imageraw, S32 x_pos, S32 y_pos, S3 // Copy sub image from frame buffer BOOL LLImageGL::setSubImageFromFrameBuffer(S32 fb_x, S32 fb_y, S32 x_pos, S32 y_pos, S32 width, S32 height) { - if (gGL.getTexUnit(0)->bind(this)) + if (gGL.getTexUnit(0)->bind(this, true)) { glCopyTexSubImage2D(GL_TEXTURE_2D, 0, fb_x, fb_y, x_pos, y_pos, width, height); mInitialized = true; diff --git a/indra/llrender/llrender.cpp b/indra/llrender/llrender.cpp index 969bfe608e..76762a1967 100644 --- a/indra/llrender/llrender.cpp +++ b/indra/llrender/llrender.cpp @@ -175,7 +175,7 @@ void LLTexUnit::disable(void) } } -bool LLTexUnit::bind(const LLImageGL* texture) +bool LLTexUnit::bind(const LLImageGL* texture, bool forceBind) { if (mIndex < 0) return false; @@ -183,25 +183,27 @@ bool LLTexUnit::bind(const LLImageGL* texture) if (texture == NULL) { - return texture->bindError(mIndex); + llwarns << "NULL LLTexUnit::bind texture" << llendl; + return false; } - if (!texture->isInitialized()) + if (!texture->isInitialized() && !forceBind) { return texture->bindDefaultImage(mIndex); } - // Disabled caching of binding state. - if (texture != NULL) + if (!texture->getTexName()) //if texture does not exist { - activate(); - enable(texture->getTarget()); - mCurrTexture = texture->getTexName(); - glBindTexture(sGLTextureType[texture->getTarget()], mCurrTexture); - texture->updateBindStats(); - return true; + return texture->bindDefaultImage(mIndex); } - return false; + + // Disabled caching of binding state. + activate(); + enable(texture->getTarget()); + mCurrTexture = texture->getTexName(); + glBindTexture(sGLTextureType[texture->getTarget()], mCurrTexture); + texture->updateBindStats(); + return true; } bool LLTexUnit::bind(LLCubeMap* cubeMap) diff --git a/indra/llrender/llrender.h b/indra/llrender/llrender.h index e604bbb84c..a9eca70744 100644 --- a/indra/llrender/llrender.h +++ b/indra/llrender/llrender.h @@ -135,12 +135,17 @@ public: // Disables the current texture unit void disable(void); - // Binds the LLImageGL to this texture unit (automatically enables the unit for the LLImageGL's texture type) - bool bind(const LLImageGL* texture); - // Binds a cubemap to this texture unit (automatically enables the texture unit for cubemaps) + // Binds the LLImageGL to this texture unit + // (automatically enables the unit for the LLImageGL's texture type) + bool bind(const LLImageGL* texture, bool forceBind = false); + + // Binds a cubemap to this texture unit + // (automatically enables the texture unit for cubemaps) bool bind(LLCubeMap* cubeMap); + // Binds a render target to this texture unit (automatically enables the texture unit for the RT's texture type) bool bind(LLRenderTarget * renderTarget, bool bindDepth = false); + // Manually binds a texture to the texture unit (automatically enables the tex unit for the given texture type) bool bindManual(eTextureType type, U32 texture); diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index ffdca84001..22260b52cf 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -544,6 +544,7 @@ void LLFloater::close(bool app_quitting) if (getHost()) { ((LLMultiFloater*)getHost())->removeFloater(this); + gFloaterView->addChild(this); } if (getSoundFlags() != SILENT @@ -1318,8 +1319,8 @@ void LLFloater::onClickEdit(void *userdata) self->mEditing = self->mEditing ? FALSE : TRUE; } -// static -void LLFloater::closeFocusedFloater() +// static +LLFloater* LLFloater::getClosableFloaterFromFocus() { LLFloater* focused_floater = NULL; @@ -1336,10 +1337,32 @@ void LLFloater::closeFocusedFloater() if (iter == sFloaterMap.end()) { // nothing found, return - return; + return NULL; + } + + // The focused floater may not be closable, + // Find and close a parental floater that is closeable, if any. + for(LLFloater* floater_to_close = focused_floater; + NULL != floater_to_close; + floater_to_close = gFloaterView->getParentFloater(floater_to_close)) + { + if(floater_to_close->isCloseable()) + { + return floater_to_close; + } } - focused_floater->close(); + return NULL; +} + +// static +void LLFloater::closeFocusedFloater() +{ + LLFloater* floater_to_close = LLFloater::getClosableFloaterFromFocus(); + if(floater_to_close) + { + floater_to_close->close(); + } // if nothing took focus after closing focused floater // give it to next floater (to allow closing multiple windows via keyboard in rapid succession) diff --git a/indra/llui/llfloater.h b/indra/llui/llfloater.h index 415419748f..b66eba8810 100644 --- a/indra/llui/llfloater.h +++ b/indra/llui/llfloater.h @@ -206,6 +206,11 @@ public: LLHandle getHandle() const { return mHandle; } + // Return a closeable floater, if any, given the current focus. + static LLFloater* getClosableFloaterFromFocus(); + + // Close the floater returned by getClosableFloaterFromFocus() and + // handle refocusing. static void closeFocusedFloater(); static void onClickClose(void *userdata); diff --git a/indra/llui/lltexteditor.cpp b/indra/llui/lltexteditor.cpp index f2562a015d..3b6ee33d38 100644 --- a/indra/llui/lltexteditor.cpp +++ b/indra/llui/lltexteditor.cpp @@ -471,9 +471,9 @@ void LLTextEditor::updateLineStartList(S32 startpos) } // if scrolled to bottom, stay at bottom - // unless user is editing text + // unless user is selecting text // do this after updating page size - if (mScrolledToBottom && mTrackBottom && !hasFocus()) + if (mScrolledToBottom && mTrackBottom && !hasMouseCapture()) { endOfDoc(); } @@ -4257,11 +4257,9 @@ S32 LLTextEditor::findHTMLToken(const std::string &line, S32 pos, BOOL reverse) std::string openers=" \t\n('\"[{<>"; std::string closers=" \t\n)'\"]}><;"; - S32 index = 0; - if (reverse) { - for (index=pos; index >= 0; index--) + for (int index=pos; index >= 0; index--) { char c = line[index]; S32 m2 = openers.find(c); @@ -4270,11 +4268,12 @@ S32 LLTextEditor::findHTMLToken(const std::string &line, S32 pos, BOOL reverse) return index+1; } } + return 0; // index is -1, don't want to return that. } else { - for (index=pos; index<(S32)line.length(); index++) + for (int index=pos; index<(S32)line.length(); index++) { char c = line[index]; S32 m2 = closers.find(c); @@ -4283,9 +4282,8 @@ S32 LLTextEditor::findHTMLToken(const std::string &line, S32 pos, BOOL reverse) return index; } } + return line.length(); } - - return index; } BOOL LLTextEditor::findHTML(const std::string &line, S32 *begin, S32 *end) const diff --git a/indra/llui/llview.cpp b/indra/llui/llview.cpp index 5ea9d6b5d8..3e7e59876c 100644 --- a/indra/llui/llview.cpp +++ b/indra/llui/llview.cpp @@ -43,7 +43,7 @@ #include "llfocusmgr.h" #include "llrect.h" #include "llstl.h" -#include "llui.h" // colors saved settings +#include "llui.h" #include "lluictrl.h" #include "llwindow.h" #include "v3color.h" @@ -713,25 +713,38 @@ BOOL LLView::handleToolTip(S32 x, S32 y, std::string& msg, LLRect* sticky_rect_s && viewp->getEnabled() && viewp->handleToolTip(local_x, local_y, msg, sticky_rect_screen )) { + // child provided a tooltip, just return + if (!msg.empty()) return TRUE; + + // otherwise, one of our children ate the event so don't traverse + // siblings however, our child did not actually provide a tooltip + // so we might want to handled = TRUE; break; } } + // get our own tooltip tool_tip = mToolTipMsg.getString(); if ( - LLUI::sShowXUINames && - (tool_tip.find(".xml", 0) == std::string::npos) && - (mName.find("Drag", 0) == std::string::npos)) + LLUI::sShowXUINames + && (tool_tip.find(".xml", 0) == std::string::npos) + && (mName.find("Drag", 0) == std::string::npos)) { tool_tip = getShowNamesToolTip(); } BOOL show_names_text_box = LLUI::sShowXUINames && dynamic_cast(this) != NULL; - if( !handled && (blockMouseEvent(x, y) || show_names_text_box)) + // don't allow any siblings to handle this event + // even if we don't have a tooltip + if (getMouseOpaque() || show_names_text_box) { + handled = TRUE; + } + if(!tool_tip.empty()) + { msg = tool_tip; // Convert rect local to screen coordinates @@ -2063,139 +2076,6 @@ LLView* LLView::findSnapRect(LLRect& new_rect, const LLCoordGL& mouse_dir, new_rect.translate(delta_x, delta_y); return snap_view; - - //// If the view is near the edge of its parent, snap it to - //// the edge. - //LLRect test_rect = getSnapRect(); - //LLRect view_rect = getSnapRect(); - //test_rect.stretch(padding); - //view_rect.stretch(padding); - - //S32 x_threshold = threshold; - //S32 y_threshold = threshold; - - //LLRect parent_local_snap_rect = mParentView->getLocalSnapRect(); - - //if (snap_type == SNAP_PARENT || snap_type == SNAP_PARENT_AND_SIBLINGS) - //{ - // if (llabs(parent_local_snap_rect.mRight - test_rect.mRight) <= x_threshold && (parent_local_snap_rect.mRight - test_rect.mRight) * mouse_dir.mX >= 0) - // { - // view_rect.translate(parent_local_snap_rect.mRight - view_rect.mRight, 0); - // snap_view = mParentView; - // x_threshold = llabs(parent_local_snap_rect.mRight - test_rect.mRight); - // } - - // if (llabs(test_rect.mLeft - parent_local_snap_rect.mLeft) <= x_threshold && test_rect.mLeft * mouse_dir.mX <= 0) - // { - // view_rect.translate(parent_local_snap_rect.mLeft - view_rect.mLeft, 0); - // snap_view = mParentView; - // x_threshold = llabs(test_rect.mLeft - parent_local_snap_rect.mLeft); - // } - - // if (llabs(test_rect.mBottom - parent_local_snap_rect.mBottom) <= y_threshold && test_rect.mBottom * mouse_dir.mY <= 0) - // { - // view_rect.translate(0, parent_local_snap_rect.mBottom - view_rect.mBottom); - // snap_view = mParentView; - // y_threshold = llabs(test_rect.mBottom - parent_local_snap_rect.mBottom); - // } - - // if (llabs(parent_local_snap_rect.mTop - test_rect.mTop) <= y_threshold && (parent_local_snap_rect.mTop - test_rect.mTop) * mouse_dir.mY >= 0) - // { - // view_rect.translate(0, parent_local_snap_rect.mTop - view_rect.mTop); - // snap_view = mParentView; - // y_threshold = llabs(parent_local_snap_rect.mTop - test_rect.mTop); - // } - //} - //if (snap_type == SNAP_SIBLINGS || snap_type == SNAP_PARENT_AND_SIBLINGS) - //{ - // for ( child_list_const_iter_t child_it = mParentView->getChildList()->begin(); - // child_it != mParentView->getChildList()->end(); ++child_it) - // { - // LLView* siblingp = *child_it; - - // // skip non-snappable views (self, invisible views, etc) - // if (!canSnapTo(siblingp)) continue; - - // LLRect sibling_rect = siblingp->getSnapRect(); - - // if (llabs(test_rect.mRight - sibling_rect.mLeft) <= x_threshold - // && (test_rect.mRight - sibling_rect.mLeft) * mouse_dir.mX <= 0) - // { - // view_rect.translate(sibling_rect.mLeft - view_rect.mRight, 0); - // if (llabs(test_rect.mTop - sibling_rect.mTop) <= y_threshold && (test_rect.mTop - sibling_rect.mTop) * mouse_dir.mY <= 0) - // { - // view_rect.translate(0, sibling_rect.mTop - test_rect.mTop); - // y_threshold = llabs(test_rect.mTop - sibling_rect.mTop); - // } - // else if (llabs(test_rect.mBottom - sibling_rect.mBottom) <= y_threshold && (test_rect.mBottom - sibling_rect.mBottom) * mouse_dir.mY <= 0) - // { - // view_rect.translate(0, sibling_rect.mBottom - test_rect.mBottom); - // y_threshold = llabs(test_rect.mBottom - sibling_rect.mBottom); - // } - // snap_view = siblingp; - // x_threshold = llabs(test_rect.mRight - sibling_rect.mLeft); - // } - - // if (llabs(test_rect.mLeft - sibling_rect.mRight) <= x_threshold - // && (test_rect.mLeft - sibling_rect.mRight) * mouse_dir.mX <= 0) - // { - // view_rect.translate(sibling_rect.mRight - view_rect.mLeft, 0); - // if (llabs(test_rect.mTop - sibling_rect.mTop) <= y_threshold && (test_rect.mTop - sibling_rect.mTop) * mouse_dir.mY <= 0) - // { - // view_rect.translate(0, sibling_rect.mTop - test_rect.mTop); - // y_threshold = llabs(test_rect.mTop - sibling_rect.mTop); - // } - // else if (llabs(test_rect.mBottom - sibling_rect.mBottom) <= y_threshold && (test_rect.mBottom - sibling_rect.mBottom) * mouse_dir.mY <= 0) - // { - // view_rect.translate(0, sibling_rect.mBottom - test_rect.mBottom); - // y_threshold = llabs(test_rect.mBottom - sibling_rect.mBottom); - // } - // snap_view = siblingp; - // x_threshold = llabs(test_rect.mLeft - sibling_rect.mRight); - // } - - // if (llabs(test_rect.mBottom - sibling_rect.mTop) <= y_threshold - // && (test_rect.mBottom - sibling_rect.mTop) * mouse_dir.mY <= 0) - // { - // view_rect.translate(0, sibling_rect.mTop - view_rect.mBottom); - // if (llabs(test_rect.mLeft - sibling_rect.mLeft) <= x_threshold && (test_rect.mLeft - sibling_rect.mLeft) * mouse_dir.mX <= 0) - // { - // view_rect.translate(sibling_rect.mLeft - test_rect.mLeft, 0); - // x_threshold = llabs(test_rect.mLeft - sibling_rect.mLeft); - // } - // else if (llabs(test_rect.mRight - sibling_rect.mRight) <= x_threshold && (test_rect.mRight - sibling_rect.mRight) * mouse_dir.mX <= 0) - // { - // view_rect.translate(sibling_rect.mRight - test_rect.mRight, 0); - // x_threshold = llabs(test_rect.mRight - sibling_rect.mRight); - // } - // snap_view = siblingp; - // y_threshold = llabs(test_rect.mBottom - sibling_rect.mTop); - // } - - // if (llabs(test_rect.mTop - sibling_rect.mBottom) <= y_threshold - // && (test_rect.mTop - sibling_rect.mBottom) * mouse_dir.mY <= 0) - // { - // view_rect.translate(0, sibling_rect.mBottom - view_rect.mTop); - // if (llabs(test_rect.mLeft - sibling_rect.mLeft) <= x_threshold && (test_rect.mLeft - sibling_rect.mLeft) * mouse_dir.mX <= 0) - // { - // view_rect.translate(sibling_rect.mLeft - test_rect.mLeft, 0); - // x_threshold = llabs(test_rect.mLeft - sibling_rect.mLeft); - // } - // else if (llabs(test_rect.mRight - sibling_rect.mRight) <= x_threshold && (test_rect.mRight - sibling_rect.mRight) * mouse_dir.mX <= 0) - // { - // view_rect.translate(sibling_rect.mRight - test_rect.mRight, 0); - // x_threshold = llabs(test_rect.mRight - sibling_rect.mRight); - // } - // snap_view = siblingp; - // y_threshold = llabs(test_rect.mTop - sibling_rect.mBottom); - // } - // } - //} - - //// shrink actual view rect back down - //view_rect.stretch(-padding); - //new_rect = view_rect; - //return snap_view; } LLView* LLView::findSnapEdge(S32& new_edge_val, const LLCoordGL& mouse_dir, ESnapEdge snap_edge, ESnapType snap_type, S32 threshold, S32 padding) diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp index 76313d82bf..da9216cef6 100644 --- a/indra/llwindow/llwindowwin32.cpp +++ b/indra/llwindow/llwindowwin32.cpp @@ -1559,7 +1559,13 @@ void LLWindowWin32::captureMouse() void LLWindowWin32::releaseMouse() { + // *NOTE:Mani ReleaseCapture will spawn new windows messages... + // which will in turn call our MainWindowProc. It therefore requires + // pausing *and more importantly resumption* of the mainlooptimeout... + // just like DispatchMessage below. + mCallbacks->handlePauseWatchdog(this); ReleaseCapture(); + mCallbacks->handleResumeWatchdog(this); } diff --git a/indra/mac_crash_logger/CrashReporter.nib/info.nib b/indra/mac_crash_logger/CrashReporter.nib/info.nib index b5417442d0..06805c0e4f 100644 --- a/indra/mac_crash_logger/CrashReporter.nib/info.nib +++ b/indra/mac_crash_logger/CrashReporter.nib/info.nib @@ -5,15 +5,13 @@ IBFramework Version 629 IBLastKnownRelativeProjectPath - ../macview.xcodeproj + ../../build-darwin-i386/SecondLife.xcodeproj IBOldestOS 5 IBOpenObjects - - 193 - + IBSystem Version - 9B18 + 9E17 targetFramework IBCarbonFramework diff --git a/indra/mac_crash_logger/CrashReporter.nib/objects.xib b/indra/mac_crash_logger/CrashReporter.nib/objects.xib index 1099f561e7..634d1c5321 100644 --- a/indra/mac_crash_logger/CrashReporter.nib/objects.xib +++ b/indra/mac_crash_logger/CrashReporter.nib/objects.xib @@ -3,9 +3,10 @@ - - Second Life appears to have crashed or frozen the last time it ran. This crash reporter collects information about your computer's hardware configuration, operating system, and some Second Life logs, all of which are used for debugging purposes only. In the space below, please briefly describe what you were doing or trying to do just prior to the crash. Thank you for your help! This report is NOT read by Customer Support. If you have billing or other questions, please go to: http://www.secondlife.com/support/ If you don't wish to send Linden Lab a crash report, press Cancel. - 20 20 231 487 + + ok + Send Report + 414 273 434 378 not! @@ -13,49 +14,47 @@ Don't Send 414 390 434 487 - - - - - ok - Send Report - 414 273 434 378 - - - - text - TRUE - 242 23 391 484 - - - remb - 1 - Remember This Choice - 415 20 433 186 - - - 0 0 454 507 + + Second Life appears to have crashed or frozen the last time it ran. This crash reporter collects information about your computer's hardware configuration, operating system, and some Second Life logs, all of which are used for debugging purposes only. In the space below, please briefly describe what you were doing or trying to do just prior to the crash. Thank you for your help! This report is NOT read by Customer Support. If you have billing or other questions, please go to: http://www.secondlife.com/support/ If you don't wish to send Linden Lab a crash report, press Cancel. + 20 20 231 487 2 3 7 Second Life Crash Logger - + + + + + + + text + TRUE + 242 23 391 484 + + + remb + Remember This Choice + 415 20 433 186 + + + 0 0 454 507 + 257 653 711 1160 0 0 768 1024 - - + + - - + + diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index a13d883682..13fc165010 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -33,10 +33,10 @@ Color4 Value - 0.0196078431372 - 0.6862745098039 - 0.9803921568627 - 1 + 1.0 + 1.0 + 1.0 + 1.0 AgentChatColor @@ -165,17 +165,6 @@ Value 0 - AsyncKeyboard - - Comment - Improves responsiveness to keyboard input when at low framerates - Persist - 1 - Type - Boolean - Value - 1 - AuctionShowFence Comment @@ -4224,18 +4213,18 @@ Value 0.0 - InstallLanguage - - Comment - Language passed from installer (for UI) - Persist - 1 - Type - String - Value - default - - InventoryAutoOpenDelay + InstallLanguage + + Comment + Language passed from installer (for UI) + Persist + 1 + Type + String + Value + default + + InventoryAutoOpenDelay Comment Seconds before automatically opening inventory when mouse is over inventory button when performing inventory drag and drop diff --git a/indra/newview/featuretable.txt b/indra/newview/featuretable.txt index 8a8ef0deac..c02ba86d6c 100644 --- a/indra/newview/featuretable.txt +++ b/indra/newview/featuretable.txt @@ -1,4 +1,4 @@ -version 17 +version 19 // NOTE: This is mostly identical to featuretable_mac.txt with a few differences // Should be combined into one table @@ -367,28 +367,40 @@ Disregard96DefaultDrawDistance 1 0 list ATI_Radeon_X300 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 list ATI_Radeon_X400 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 list ATI_Radeon_X500 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 list ATI_Radeon_X600 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 list ATI_Radeon_X700 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 list ATI_Radeon_X1300 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 UseStartScreen 0 0 list ATI_Radeon_X1400 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 list ATI_Radeon_X1500 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 UseStartScreen 0 0 list ATI_Radeon_X1600 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 list ATI_Radeon_X1700 Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 list ATI_Mobility_Radeon_X1xxx Disregard128DefaultDrawDistance 1 0 +RenderVBOEnable 1 0 + list ATI_Radeon_HD_2300 Disregard128DefaultDrawDistance 1 0 list ATI_Radeon_HD_2400 diff --git a/indra/newview/featuretable_linux.txt b/indra/newview/featuretable_linux.txt index 08a9794c61..09105b8d88 100644 --- a/indra/newview/featuretable_linux.txt +++ b/indra/newview/featuretable_linux.txt @@ -1,4 +1,4 @@ -version 17 +version 19 // NOTE: This is mostly identical to featuretable_mac.txt with a few differences // Should be combined into one table diff --git a/indra/newview/featuretable_mac.txt b/indra/newview/featuretable_mac.txt index 323683462a..fd2496d8ad 100644 --- a/indra/newview/featuretable_mac.txt +++ b/indra/newview/featuretable_mac.txt @@ -1,4 +1,4 @@ -version 16 +version 19 // NOTE: This is mostly identical to featuretable_mac.txt with a few differences // Should be combined into one table diff --git a/indra/newview/gpu_table.txt b/indra/newview/gpu_table.txt index 44d66a606b..748400532f 100644 --- a/indra/newview/gpu_table.txt +++ b/indra/newview/gpu_table.txt @@ -26,6 +26,7 @@ ATI All-in-Wonder 7500 .*ATI.*All-in-Wonder 75.* 0 1 ATI All-in-Wonder 8500 .*ATI.*All-in-Wonder 85.* 0 1 ATI All-in-Wonder 9200 .*ATI.*All-in-Wonder 92.* 0 1 ATI All-in-Wonder 9xxx .*ATI.*All-in-Wonder 9.* 1 1 +ATI All-in-Wonder HD .*ATI.*All-in-Wonder HD.* 1 1 ATI All-in-Wonder X600 .*ATI.*All-in-Wonder X6.* 1 1 ATI All-in-Wonder X800 .*ATI.*All-in-Wonder X8.* 2 1 ATI All-in-Wonder X1800 .*ATI.*All-in-Wonder X18.* 3 1 @@ -35,6 +36,7 @@ ATI All-in-Wonder Radeon .*ATI.*All-in-Wonder Radeon.* 0 1 ATI ASUS A9xxx .*ATI.*ASUS.*A9.* 1 1 ATI ASUS AH24xx .*ATI.*ASUS.*AH24.* 1 1 ATI ASUS AH26xx .*ATI.*ASUS.*AH26.* 3 1 +ATI ASUS AH34xx .*ATI.*ASUS.*AH34.* 1 1 ATI ASUS AH36xx .*ATI.*ASUS.*AH36.* 3 1 ATI ASUS AH46xx .*ATI.*ASUS.*AH46.* 3 1 ATI ASUS AX3xx .*ATI.*ASUS.*AX3.* 1 1 @@ -46,12 +48,12 @@ ATI ASUS EAH34xx .*ATI.*ASUS.*EAH34.* 1 1 ATI ASUS EAH36xx .*ATI.*ASUS.*EAH36.* 3 1 ATI ASUS EAH38xx .*ATI.*ASUS.*EAH38.* 3 1 ATI ASUS EAH48xx .*ATI.*ASUS.*EAH48.* 3 1 -ATI ASUS X1xxx .*ATI.*ASUS.*X1.* 2 1 -ATI ASUS X7xx .*ATI.*ASUS.*X7.* 1 1 -ATI Diamond X550 .*ATI.*Diamond X550.* 1 1 -ATI Diamond X13xx .*ATI.*Diamond X13.* 1 1 -ATI Diamond X16xx .*ATI.*Diamond X16.* 1 1 -ATI Diamond X19xx .*ATI.*Diamond X19.* 1 1 +ATI Radeon X1xxx .*ATI.*ASUS.*X1.* 2 1 +ATI Radeon X7xx .*ATI.*ASUS.*X7.* 1 1 +ATI Radeon X500 .*ATI.*Diamond X5.* 1 1 +ATI Radeon X13xx .*ATI.*Diamond X13.* 1 1 +ATI Radeon X16xx .*ATI.*Diamond X16.* 1 1 +ATI Radeon X19xx .*ATI.*Diamond X19.* 1 1 ATI Display Adapter .*ATI.*display adapter.* 0 1 ATI FireGL 5200 .*ATI.*FireGL V52.* 0 1 ATI FireGL 5xxx .*ATI.*FireGL V5.* 1 1 @@ -63,6 +65,8 @@ ATI IGP 340M .*ATI.*IGP.*340M.* 0 0 ATI M52 .*ATI.*M52.* 1 1 ATI M54 .*ATI.*M54.* 1 1 ATI M56 .*ATI.*M56.* 1 1 +ATI M71 .*ATI.*M71.* 1 1 +ATI M72 .*ATI.*M72.* 1 1 ATI M76 .*ATI.*M76.* 3 1 ATI Mobility Radeon 7xxx .*ATI.*Mobility.*Radeon 7.* 0 1 ATI Mobility Radeon 8xxx .*ATI.*Mobility.*Radeon 8.* 0 1 @@ -86,9 +90,13 @@ ATI Radeon HD 2300 .*ATI.*Radeon HD 23.* 0 1 ATI Radeon HD 2400 .*ATI.*Radeon HD.*24.* 1 1 ATI Radeon HD 2600 .*ATI.*Radeon HD 26.* 2 1 ATI Radeon HD 2900 .*ATI.*Radeon HD 29.* 3 1 +ATI Radeon HD 3200 .*ATI.*Radeon HD.*32.* 1 1 +ATI Radeon HD 3300 .*ATI.*Radeon HD.*33.* 1 1 ATI Radeon HD 3400 .*ATI.*Radeon HD.*34.* 1 1 ATI Radeon HD 3600 .*ATI.*Radeon HD.*36.* 3 1 ATI Radeon HD 3800 .*ATI.*Radeon HD.*38.* 3 1 +ATI Radeon HD 4300 .*ATI.*Radeon HD 43.* 1 1 +ATI Radeon HD 4600 .*ATI.*Radeon HD 46.* 3 1 ATI Radeon HD 4800 .*ATI.*Radeon HD.*48.* 3 1 ATI Radeon OpenGL .*ATI.*Radeon OpenGL.* 0 0 ATI Radeon 2100 .*ATI.*Radeon 21.* 0 1 @@ -137,8 +145,8 @@ Intel 865G .*Intel.*865G 0 0 Intel 900 .*Intel.*900.*900 0 0 Intel 915GM .*Intel.*915GM 0 0 Intel 915G .*Intel.*915G 0 0 -Intel 945GM .*Intel.*945GM 0 1 -Intel 945G .*Intel.*945G 0 1 +Intel 945GM .*Intel.*945GM.* 0 1 +Intel 945G .*Intel.*945G.* 0 1 Intel 950 .*Intel.*950.* 0 1 Intel 965 .*Intel.*965.* 0 1 Intel G33 .*Intel.*G33.* 0 0 @@ -180,17 +188,22 @@ NVIDIA GeForce 7500 .*NVIDIA.*GeForce 75.* 1 1 NVIDIA GeForce 7600 .*NVIDIA.*GeForce 76.* 2 1 NVIDIA GeForce 7800 .*NVIDIA.*GeForce.*78.* 2 1 NVIDIA GeForce 7900 .*NVIDIA.*GeForce 79.* 2 1 +NVIDIA GeForce 8100 .*NVIDIA.*GeForce 81.* 1 1 NVIDIA GeForce 8200 .*NVIDIA.*GeForce 82.* 1 1 NVIDIA GeForce 8300 .*NVIDIA.*GeForce 83.* 1 1 NVIDIA GeForce 8400 .*NVIDIA.*GeForce 84.* 1 1 -NVIDIA GeForce 8500 .*NVIDIA.*GeForce 85.* 3 1 +NVIDIA GeForce 8500 .*GeForce 85.* 3 1 +NVIDIA GeForce 8600M .*NVIDIA.*GeForce.*8600M.* 1 1 NVIDIA GeForce 8600 .*NVIDIA.*GeForce 86.* 3 1 NVIDIA GeForce 8700 .*NVIDIA.*GeForce 87.* 3 1 NVIDIA GeForce 8800 .*NVIDIA.*GeForce 88.* 3 1 NVIDIA GeForce 9300M .*NVIDIA.*GeForce 9300M.* 1 1 +NVIDIA GeForce 9400M .*NVIDIA.*GeForce 9400M.* 1 1 NVIDIA GeForce 9500M .*NVIDIA.*GeForce 9500M.* 2 1 +NVIDIA GeForce 9600M .*NVIDIA.*GeForce 9600M.* 2 1 NVIDIA GeForce 9700M .*NVIDIA.*GeForce 9700M.* 2 1 NVIDIA GeForce 9300 .*NVIDIA.*GeForce 93.* 1 1 +NVIDIA GeForce 9400 .*GeForce 94.* 1 1 NVIDIA GeForce 9500 .*NVIDIA.*GeForce 95.* 2 1 NVIDIA GeForce 9600 .*NVIDIA.*GeForce 96.* 3 1 NVIDIA GeForce 9800 .*NVIDIA.*GeForce 98.* 3 1 @@ -225,6 +238,10 @@ NVIDIA GeForce Go 7800 .*NVIDIA.*GeForce Go 78.* 2 1 NVIDIA GeForce Go 7900 .*NVIDIA.*GeForce Go 79.* 2 1 NVIDIA GeForce GTX 260 .*NVIDIA.*GeForce GTX 26.* 3 1 NVIDIA GeForce GTX 280 .*NVIDIA.*GeForce GTX 28.* 3 1 +NVIDIA D9M .*D9M.* 1 1 +NVIDIA G84 .*G84.* 1 1 +NVIDIA G92 .*G92.* 3 1 +NVIDIA G94 .*G94.* 3 1 NVIDIA GeForce Go 6 .*GeForce Go 6.* 1 1 NVIDIA NB9M .*GeForce NB9M.* 1 1 NVIDIA NB9P .*GeForce NB9P.* 1 1 @@ -234,6 +251,8 @@ NVIDIA NV17 .*GeForce NV17.* 0 1 NVIDIA NV34 .*NVIDIA.*NV34.* 0 1 NVIDIA NV36 .*GeForce NV36.* 1 1 NVIDIA NV43 .*NVIDIA.*NV43.* 1 1 +NVIDIA NV44 .*NVIDIA.*NV44.* 1 1 +NVIDIA nForce .*NVIDIA.*nForce.* 0 0 NVIDIA MCP78 .*NVIDIA.*MCP78.* 1 1 NVIDIA Quadro2 .*Quadro2.* 0 1 NVIDIA Quadro4 .*Quadro4.* 0 1 @@ -242,10 +261,12 @@ NVIDIA Quadro FX 4500 .*Quadro.*FX.*4500.* 3 1 NVIDIA Quadro FX .*Quadro FX.* 1 1 NVIDIA Quadro NVS .*Quadro NVS.* 0 1 NVIDIA RIVA TNT .*RIVA TNT.* 0 0 +NVIDIA PCI .*NVIDIA.*/PCI/SSE2 0 0 S3 .*S3 Graphics.* 0 0 SiS SiS.* 0 0 Trident Trident.* 0 0 Tungsten Graphics Tungsten.* 0 0 XGI XGI.* 0 0 VIA VIA.* 0 0 - +Apple Generic Apple.*Generic.* 0 0 +Apple Software Renderer Apple.*Software Renderer.* 0 0 diff --git a/indra/newview/installers/windows/lang_de.nsi b/indra/newview/installers/windows/lang_de.nsi index 911ed74348..b717a4d3a5 100644 Binary files a/indra/newview/installers/windows/lang_de.nsi and b/indra/newview/installers/windows/lang_de.nsi differ diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index ac399b45df..b8b08855a8 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -191,26 +191,17 @@ //---------------------------------------------------------------------------- // viewer.cpp - these are only used in viewer, should be easily moved. -extern void disable_win_error_reporting(); #if LL_DARWIN -#include extern void init_apple_menu(const char* product); -extern OSErr AEGURLHandler(const AppleEvent *messagein, AppleEvent *reply, long refIn); -extern OSErr AEQuitHandler(const AppleEvent *messagein, AppleEvent *reply, long refIn); -extern OSStatus simpleDialogHandler(EventHandlerCallRef handler, EventRef event, void *userdata); -#include #endif // LL_DARWIN - extern BOOL gRandomizeFramerate; extern BOOL gPeriodicSlowFrame; extern BOOL gDebugGL; //////////////////////////////////////////////////////////// // All from the last globals push... -BOOL gHandleKeysAsync = FALSE; - const F32 DEFAULT_AFK_TIMEOUT = 5.f * 60.f; // time with no input before user flagged as Away From Keyboard F32 gSimLastTime; // Used in LLAppViewer::init and send_stats() @@ -241,7 +232,7 @@ F32 gFPSClamped = 10.f; // Pretend we start at target rate. F32 gFrameDTClamped = 0.f; // Time between adjacent checks to network for packets U64 gStartTime = 0; // gStartTime is "private", used only to calculate gFrameTimeSeconds U32 gFrameStalls = 0; -const F64 FRAME_STALL_THRESHOLD = 5.0; +const F64 FRAME_STALL_THRESHOLD = 1.0; LLTimer gRenderStartTime; LLFrameTimer gForegroundTime; @@ -311,6 +302,8 @@ std::string gLoginPage; std::vector gLoginURIs; static std::string gHelperURI; +LLAppViewer::LLUpdaterInfo *LLAppViewer::sUpdaterInfo = NULL ; + void idle_afk_check() { // check idle timers @@ -412,7 +405,6 @@ static void settings_to_globals() gShowObjectUpdates = gSavedSettings.getBOOL("ShowObjectUpdates"); gMapScale = gSavedSettings.getF32("MapScale"); gMiniMapScale = gSavedSettings.getF32("MiniMapScale"); - gHandleKeysAsync = gSavedSettings.getBOOL("AsyncKeyboard"); LLHoverView::sShowHoverTips = gSavedSettings.getBOOL("ShowHoverTips"); LLCubeMap::sUseCubeMaps = LLFeatureManager::getInstance()->isFeatureAvailable("RenderCubeMap"); @@ -665,6 +657,7 @@ bool LLAppViewer::init() ui_audio_callback, &LLUI::sGLScaleFactor); LLWeb::initClass(); // do this after LLUI + LLTextEditor::setURLCallbacks(&LLWeb::loadURL, &LLURLDispatcher::dispatchFromTextEditor, &LLURLDispatcher::dispatchFromTextEditor); @@ -685,7 +678,6 @@ bool LLAppViewer::init() // load MIME type -> media impl mappings LLMIMETypes::parseMIMETypes( std::string("mime_types.xml") ); - // Copy settings to globals. *TODO: Remove or move to appropriage class initializers settings_to_globals(); // Setup settings listeners @@ -829,7 +821,10 @@ bool LLAppViewer::init() } } - + + // save the graphics card + gDebugInfo["GraphicsCard"] = LLFeatureManager::getInstance()->getGPUString(); + // Save the current version to the prefs file gSavedSettings.setString("LastRunVersion", gCurrentVersion); @@ -885,12 +880,10 @@ bool LLAppViewer::mainLoop() { LLFastTimer t2(LLFastTimer::FTM_MESSAGES); - #if LL_WINDOWS - if (!LLWinDebug::checkExceptionHandler()) + if (!restoreErrorTrap()) { - llwarns << " Someone took over my exception handler (post messagehandling)!" << llendl; + llwarns << " Someone took over my signal/exception handler (post messagehandling)!" << llendl; } - #endif gViewerWindow->mWindow->gatherInput(); } @@ -946,7 +939,7 @@ bool LLAppViewer::mainLoop() resumeMainloopTimeout(); } - + if (gDoDisconnect && (LLStartUp::getStartupState() == STATE_STARTED)) { pauseMainloopTimeout(); @@ -1362,6 +1355,10 @@ bool LLAppViewer::cleanup() delete sImageDecodeThread; sImageDecodeThread = NULL; + //Note: + //LLViewerMedia::cleanupClass() has to be put before gImageList.shutdown() + //because some new image might be generated during cleaning up media. --bao + LLViewerMedia::cleanupClass(); gImageList.shutdown(); // shutdown again in case a callback added something LLUIImageList::getInstance()->cleanUp(); @@ -1387,14 +1384,17 @@ bool LLAppViewer::cleanup() LLWatchdog::getInstance()->cleanup(); end_messaging_system(); + llinfos << "Message system deleted." << llendflush; // *NOTE:Mani - The following call is not thread safe. LLCurl::cleanupClass(); + llinfos << "LLCurl cleaned up." << llendflush; // If we're exiting to launch an URL, do that here so the screen // is at the right resolution before we launch IE. if (!gLaunchFileOnQuit.empty()) { + llinfos << "Launch file on quit." << llendflush; #if LL_WINDOWS // Indicate an application is starting. SetCursor(LoadCursor(NULL, IDC_WAIT)); @@ -1404,9 +1404,8 @@ bool LLAppViewer::cleanup() ms_sleep(1000); LLWeb::loadURLExternal( gLaunchFileOnQuit ); + llinfos << "File launched." << llendflush; } - - LLViewerMedia::cleanupClass(); llinfos << "Goodbye" << llendflush; @@ -1414,6 +1413,25 @@ bool LLAppViewer::cleanup() return true; } +// A callback for llerrs to call during the watchdog error. +void watchdog_llerrs_callback(const std::string &error_string) +{ + gLLErrorActivated = true; + +#ifdef LL_WINDOWS + RaiseException(0,0,0,0); +#else + raise(SIGQUIT); +#endif +} + +// A callback for the watchdog to call. +void watchdog_killer_callback() +{ + LLError::setFatalFunction(watchdog_llerrs_callback); + llerrs << "Watchdog killer event" << llendl; +} + bool LLAppViewer::initThreads() { #if MEM_TRACK_MEM @@ -1423,10 +1441,11 @@ bool LLAppViewer::initThreads() #endif const S32 NEVER_SUBMIT_REPORT = 2; - if(TRUE == gSavedSettings.getBOOL("WatchdogEnabled") - && (gCrashSettings.getS32(CRASH_BEHAVIOR_SETTING) != NEVER_SUBMIT_REPORT)) + bool use_watchdog = gSavedSettings.getBOOL("WatchdogEnabled"); + bool send_reports = gCrashSettings.getS32(CRASH_BEHAVIOR_SETTING) != NEVER_SUBMIT_REPORT; + if(use_watchdog && send_reports) { - LLWatchdog::getInstance()->init(); + LLWatchdog::getInstance()->init(watchdog_killer_callback); } LLVFSThread::initClass(enable_threads && true); @@ -2013,7 +2032,7 @@ bool LLAppViewer::initConfiguration() } initMarkerFile(); - + #if LL_SEND_CRASH_REPORTS if (gLastExecEvent == LAST_EXEC_FROZE) { @@ -2035,52 +2054,8 @@ bool LLAppViewer::initConfiguration() { llinfos << "Sending crash report." << llendl; -#if LL_WINDOWS - std::string exe_path = gDirUtilp->getAppRODataDir(); - exe_path += gDirUtilp->getDirDelimiter(); - exe_path += "win_crash_logger.exe"; - - std::string arg_string = "-previous "; - // Spawn crash logger. - // NEEDS to wait until completion, otherwise log files will get smashed. - _spawnl(_P_WAIT, exe_path.c_str(), exe_path.c_str(), arg_string.c_str(), NULL); -#elif LL_DARWIN - std::string command_str; - command_str = "mac-crash-logger.app/Contents/MacOS/mac-crash-logger "; - command_str += "-previous"; - // XXX -- We need to exit fullscreen mode for this to work. - // XXX -- system() also doesn't wait for completion. Hmm... - system(command_str.c_str()); /* Flawfinder: Ignore */ -#elif LL_LINUX || LL_SOLARIS - std::string cmd =gDirUtilp->getAppRODataDir(); - cmd += gDirUtilp->getDirDelimiter(); -#if LL_LINUX - cmd += "linux-crash-logger.bin"; -#else // LL_SOLARIS - cmd += "bin/solaris-crash-logger"; -#endif // LL_LINUX - char* const cmdargv[] = - {(char*)cmd.c_str(), - (char*)"-previous", - NULL}; - fflush(NULL); // flush all buffers before the child inherits them - pid_t pid = fork(); - if (pid == 0) - { // child - execv(cmd.c_str(), cmdargv); /* Flawfinder: Ignore */ - llwarns << "execv failure when trying to start " << cmd << llendl; - _exit(1); // avoid atexit() - } else { - if (pid > 0) - { - // wait for child proc to die - int childExitStatus; - waitpid(pid, &childExitStatus, 0); - } else { - llwarns << "fork failure." << llendl; - } - } -#endif + bool report_freeze = true; + handleCrashReporting(report_freeze); } else { @@ -2246,7 +2221,6 @@ void LLAppViewer::cleanupSavedSettings() gSavedSettings.setF32("MapScale", gMapScale ); gSavedSettings.setF32("MiniMapScale", gMiniMapScale ); - gSavedSettings.setBOOL("AsyncKeyboard", gHandleKeysAsync); gSavedSettings.setBOOL("ShowHoverTips", LLHoverView::sShowHoverTips); // Some things are cached in LLAgent. @@ -2284,7 +2258,7 @@ void LLAppViewer::writeSystemInfo() gDebugInfo["RAMInfo"]["Physical"] = (LLSD::Integer)(gSysMemory.getPhysicalMemoryKB()); gDebugInfo["RAMInfo"]["Allocated"] = (LLSD::Integer)(gMemoryAllocated>>10); // MB -> KB gDebugInfo["OSInfo"] = getOSInfo().getOSStringSimple(); - + // The user is not logged on yet, but record the current grid choice login url // which may have been the intended grid. This can b gDebugInfo["GridName"] = LLViewerLogin::getInstance()->getGridLabel(); @@ -2295,6 +2269,13 @@ void LLAppViewer::writeSystemInfo() gDebugInfo["MainloopThreadID"] = (S32)thread_id; #endif + // "CrashNotHandled" is set here, while things are running well, + // in case of a freeze. If there is a freeze, the crash logger will be launched + // and can read this value from the debug_info.log. + // If the crash is handled by LLAppViewer::handleViewerCrash, ie not a freeze, + // then the value of "CrashNotHandled" will be set to true. + gDebugInfo["CrashNotHandled"] = (LLSD::Boolean)true; + // Dump some debugging info LL_INFOS("SystemInfo") << gSecondLife << " version " << LL_VERSION_MAJOR << "." << LL_VERSION_MINOR << "." << LL_VERSION_PATCH @@ -2369,6 +2350,9 @@ void LLAppViewer::handleViewerCrash() gDebugInfo["CAFilename"] = gDirUtilp->getCAFile(); gDebugInfo["ViewerExePath"] = gDirUtilp->getExecutablePathAndName(); gDebugInfo["CurrentPath"] = gDirUtilp->getCurPath(); + gDebugInfo["SessionLength"] = F32(LLFrameTimer::getElapsedSeconds()); + gDebugInfo["StartupState"] = LLStartUp::getStartupStateString(); + if(gLogoutInProgress) { gDebugInfo["LastExecEvent"] = LAST_EXEC_LOGOUT_CRASH; @@ -2394,6 +2378,9 @@ void LLAppViewer::handleViewerCrash() gDebugInfo["MainloopTimeoutState"] = LLAppViewer::instance()->mMainloopTimeout->getState(); } + // The crash is being handled here so set this value to false. + // Otherwise the crash logger will think this crash was a freeze. + gDebugInfo["CrashNotHandled"] = (LLSD::Boolean)false; //Write out the crash status file //Use marker file style setup, as that's the simplest, especially since @@ -3857,6 +3844,11 @@ void LLAppViewer::pauseMainloopTimeout() void LLAppViewer::pingMainloopTimeout(const std::string& state, F32 secs) { +// if(!restoreErrorTrap()) +// { +// llwarns << "!!!!!!!!!!!!! Its an error trap!!!!" << state << llendl; +// } + if(mMainloopTimeout) { if(secs < 0.0f) @@ -3869,3 +3861,42 @@ void LLAppViewer::pingMainloopTimeout(const std::string& state, F32 secs) } } +void LLAppViewer::handleLoginComplete() +{ + initMainloopTimeout("Mainloop Init"); + + // Store some data to DebugInfo in case of a freeze. + gDebugInfo["ClientInfo"]["Name"] = gSavedSettings.getString("VersionChannelName"); + + gDebugInfo["ClientInfo"]["MajorVersion"] = LL_VERSION_MAJOR; + gDebugInfo["ClientInfo"]["MinorVersion"] = LL_VERSION_MINOR; + gDebugInfo["ClientInfo"]["PatchVersion"] = LL_VERSION_PATCH; + gDebugInfo["ClientInfo"]["BuildVersion"] = LL_VERSION_BUILD; + + LLParcel* parcel = LLViewerParcelMgr::getInstance()->getAgentParcel(); + if ( parcel && parcel->getMusicURL()[0]) + { + gDebugInfo["ParcelMusicURL"] = parcel->getMusicURL(); + } + if ( parcel && parcel->getMediaURL()[0]) + { + gDebugInfo["ParcelMediaURL"] = parcel->getMediaURL(); + } + + gDebugInfo["SettingsFilename"] = gSavedSettings.getString("ClientSettingsFile"); + gDebugInfo["CAFilename"] = gDirUtilp->getCAFile(); + gDebugInfo["ViewerExePath"] = gDirUtilp->getExecutablePathAndName(); + gDebugInfo["CurrentPath"] = gDirUtilp->getCurPath(); + + if(gAgent.getRegion()) + { + gDebugInfo["CurrentSimHost"] = gAgent.getRegionHost().getHostName(); + gDebugInfo["CurrentRegion"] = gAgent.getRegion()->getName(); + } + + if(LLAppViewer::instance()->mMainloopTimeout) + { + gDebugInfo["MainloopTimeoutState"] = LLAppViewer::instance()->mMainloopTimeout->getState(); + } + writeDebugInfo(); +} diff --git a/indra/newview/llappviewer.h b/indra/newview/llappviewer.h index e6856e9744..41081237c7 100644 --- a/indra/newview/llappviewer.h +++ b/indra/newview/llappviewer.h @@ -77,7 +77,9 @@ public: // Report true if under the control of a debugger. A null-op default. virtual bool beingDebugged() { return false; } - virtual void handleCrashReporting() = 0; // What to do with crash report? + virtual bool restoreErrorTrap() = 0; // Require platform specific override to reset error handling mechanism. + // return false if the error trap needed restoration. + virtual void handleCrashReporting(bool reportFreeze = false) = 0; // What to do with crash report? virtual void handleSyncCrashTrace() = 0; // any low-level crash-prep that has to happen in the context of the crashing thread before the crash report is delivered. static void handleViewerCrash(); // Hey! The viewer crashed. Do this, soon. static void handleSyncViewerCrash(); // Hey! The viewer crashed. Do this right NOW in the context of the crashing thread. @@ -140,6 +142,9 @@ public: void resumeMainloopTimeout(const std::string& state = "", F32 secs = -1.0f); void pingMainloopTimeout(const std::string& state, F32 secs = -1.0f); + // Handle the 'login completed' event. + // *NOTE:Mani Fix this for login abstraction!! + void handleLoginComplete(); protected: virtual bool initWindow(); // Initialize the viewer's window. @@ -222,6 +227,15 @@ private: // for tracking viewer<->region circuit death bool mAgentRegionLastAlive; LLUUID mAgentRegionLastID; + +public: + //some information for updater + typedef struct + { + std::string mUpdateExePath; + std::ostringstream mParams; + }LLUpdaterInfo ; + static LLUpdaterInfo *sUpdaterInfo ; }; // consts from viewer.h @@ -232,7 +246,6 @@ const S32 AGENT_UPDATES_PER_SECOND = 10; // // "// llstartup" indicates that llstartup is the only client for this global. -extern BOOL gHandleKeysAsync; // gSavedSettings used by llviewerdisplay.cpp & llviewermenu.cpp extern LLSD gDebugInfo; extern BOOL gAllowIdleAFK; diff --git a/indra/newview/llappviewerlinux.cpp b/indra/newview/llappviewerlinux.cpp index 2a5f0ea270..1df4f81416 100644 --- a/indra/newview/llappviewerlinux.cpp +++ b/indra/newview/llappviewerlinux.cpp @@ -334,6 +334,13 @@ bool LLAppViewerLinux::init() return LLAppViewer::init(); } +bool LLAppViewerLinux::restoreErrorTrap() +{ + // *NOTE:Mani there is a case for implementing this or the mac. + // Linux doesn't need it to my knowledge. + return true; +} + ///////////////////////////////////////// #if LL_DBUS_ENABLED @@ -526,57 +533,90 @@ void LLAppViewerLinux::handleSyncCrashTrace() # endif // LL_ELFBIN } -void LLAppViewerLinux::handleCrashReporting() +void LLAppViewerLinux::handleCrashReporting(bool reportFreeze) { - const S32 cb = gCrashSettings.getS32(CRASH_BEHAVIOR_SETTING); - - // Always generate the report, have the logger do the asking, and - // don't wait for the logger before exiting (-> total cleanup). - if (CRASH_BEHAVIOR_NEVER_SEND != cb) - { - // launch the actual crash logger - const char* ask_dialog = "-dialog"; - if (CRASH_BEHAVIOR_ASK != cb) - ask_dialog = ""; // omit '-dialog' option - std::string cmd =gDirUtilp->getAppRODataDir(); - cmd += gDirUtilp->getDirDelimiter(); - cmd += "linux-crash-logger.bin"; - const char * cmdargv[] = - {cmd.c_str(), - ask_dialog, - "-user", - (char*)LLViewerLogin::getInstance()->getGridLabel().c_str(), - "-name", - LLAppViewer::instance()->getSecondLifeTitle().c_str(), + std::string cmd =gDirUtilp->getAppRODataDir(); + cmd += gDirUtilp->getDirDelimiter(); +#if LL_LINUX + cmd += "linux-crash-logger.bin"; +#else // LL_SOLARIS + cmd += "bin/solaris-crash-logger"; +#endif // LL_LINUX + + if(reportFreeze) + { + char* const cmdargv[] = + {(char*)cmd.c_str(), + (char*)"-previous", NULL}; - fflush(NULL); + + fflush(NULL); // flush all buffers before the child inherits them pid_t pid = fork(); if (pid == 0) { // child - execv(cmd.c_str(), (char* const*) cmdargv); /* Flawfinder: ignore */ + execv(cmd.c_str(), cmdargv); /* Flawfinder: Ignore */ llwarns << "execv failure when trying to start " << cmd << llendl; _exit(1); // avoid atexit() - } - else - { + } else { if (pid > 0) { - // DO NOT wait for child proc to die; we want - // the logger to outlive us while we quit to - // free up the screen/keyboard/etc. - ////int childExitStatus; - ////waitpid(pid, &childExitStatus, 0); + // wait for child proc to die + int childExitStatus; + waitpid(pid, &childExitStatus, 0); + } else { + llwarns << "fork failure." << llendl; + } + } + } + else + { + const S32 cb = gCrashSettings.getS32(CRASH_BEHAVIOR_SETTING); + + // Always generate the report, have the logger do the asking, and + // don't wait for the logger before exiting (-> total cleanup). + if (CRASH_BEHAVIOR_NEVER_SEND != cb) + { + // launch the actual crash logger + const char* ask_dialog = "-dialog"; + if (CRASH_BEHAVIOR_ASK != cb) + ask_dialog = ""; // omit '-dialog' option + const char * cmdargv[] = + {cmd.c_str(), + ask_dialog, + "-user", + (char*)LLViewerLogin::getInstance()->getGridLabel().c_str(), + "-name", + LLAppViewer::instance()->getSecondLifeTitle().c_str(), + NULL}; + fflush(NULL); + pid_t pid = fork(); + if (pid == 0) + { // child + execv(cmd.c_str(), (char* const*) cmdargv); /* Flawfinder: ignore */ + llwarns << "execv failure when trying to start " << cmd << llendl; + _exit(1); // avoid atexit() } else { - llwarns << "fork failure." << llendl; + if (pid > 0) + { + // DO NOT wait for child proc to die; we want + // the logger to outlive us while we quit to + // free up the screen/keyboard/etc. + ////int childExitStatus; + ////waitpid(pid, &childExitStatus, 0); + } + else + { + llwarns << "fork failure." << llendl; + } } } + // Sometimes signals don't seem to quit the viewer. Also, we may + // have been called explicitly instead of from a signal handler. + // Make sure we exit so as to not totally confuse the user. + _exit(1); // avoid atexit(), else we may re-crash in dtors. } - // Sometimes signals don't seem to quit the viewer. Also, we may - // have been called explicitly instead of from a signal handler. - // Make sure we exit so as to not totally confuse the user. - _exit(1); // avoid atexit(), else we may re-crash in dtors. } bool LLAppViewerLinux::beingDebugged() diff --git a/indra/newview/llappviewerlinux.h b/indra/newview/llappviewerlinux.h index a0e48ea388..2929e8a1b0 100644 --- a/indra/newview/llappviewerlinux.h +++ b/indra/newview/llappviewerlinux.h @@ -61,8 +61,9 @@ public: protected: virtual bool beingDebugged(); - - virtual void handleCrashReporting(); + + virtual bool restoreErrorTrap(); + virtual void handleCrashReporting(bool reportFreeze); virtual void handleSyncCrashTrace(); virtual bool initLogging(); diff --git a/indra/newview/llappviewermacosx.cpp b/indra/newview/llappviewermacosx.cpp index 81990b0464..01e6483adc 100644 --- a/indra/newview/llappviewermacosx.cpp +++ b/indra/newview/llappviewermacosx.cpp @@ -48,7 +48,7 @@ #include "llurldispatcher.h" #include #include "lldir.h" - +#include class LLWebBrowserCtrl; // for LLURLDispatcher namespace @@ -196,22 +196,106 @@ bool LLAppViewerMacOSX::initParseCommandLine(LLCommandLineParser& clp) return true; } +// *FIX:Mani It would be nice to provide a clean interface to get the +// default_unix_signal_handler for the LLApp class. +extern void default_unix_signal_handler(int, siginfo_t *, void *); +bool LLAppViewerMacOSX::restoreErrorTrap() +{ + // This method intends to reinstate signal handlers. + // *NOTE:Mani It was found that the first execution of a shader was overriding + // our initial signal handlers somehow. + // This method will be called (at least) once per mainloop execution. + // *NOTE:Mani The signals used below are copied over from the + // setup_signals() func in LLApp.cpp + // LLApp could use some way of overriding that func, but for this viewer + // fix I opt to avoid affecting the server code. + + // Set up signal handlers that may result in program termination + // + struct sigaction act; + struct sigaction old_act; + act.sa_sigaction = default_unix_signal_handler; + sigemptyset( &act.sa_mask ); + act.sa_flags = SA_SIGINFO; + + unsigned int reset_count = 0; + +#define SET_SIG(S) sigaction(SIGABRT, &act, &old_act); \ + if((unsigned int)act.sa_sigaction != (unsigned int) old_act.sa_sigaction) \ + ++reset_count; + // Synchronous signals + SET_SIG(SIGABRT) + SET_SIG(SIGALRM) + SET_SIG(SIGBUS) + SET_SIG(SIGFPE) + SET_SIG(SIGHUP) + SET_SIG(SIGILL) + SET_SIG(SIGPIPE) + SET_SIG(SIGSEGV) + SET_SIG(SIGSYS) + + SET_SIG(LL_HEARTBEAT_SIGNAL) + SET_SIG(LL_SMACKDOWN_SIGNAL) + + // Asynchronous signals that are normally ignored + SET_SIG(SIGCHLD) + SET_SIG(SIGUSR2) + + // Asynchronous signals that result in attempted graceful exit + SET_SIG(SIGHUP) + SET_SIG(SIGTERM) + SET_SIG(SIGINT) + + // Asynchronous signals that result in core + SET_SIG(SIGQUIT) +#undef SET_SIG + + return reset_count == 0; +} + void LLAppViewerMacOSX::handleSyncCrashTrace() { // do nothing } -void LLAppViewerMacOSX::handleCrashReporting() +void LLAppViewerMacOSX::handleCrashReporting(bool reportFreeze) { - // Macintosh std::string command_str; - command_str += "open mac-crash-logger.app"; + //command_str = "open Second Life.app/Contents/Resources/mac-crash-logger.app"; + command_str = "mac-crash-logger.app/Contents/MacOS/mac-crash-logger"; - clear_signals(); - llinfos << "Launching crash reporter using: '" << command_str << "'" << llendl; - system(command_str.c_str()); /* Flawfinder: ignore */ - llinfos << "returned from crash reporter... dying" << llendl; - _exit(1); + FSRef appRef; + Boolean isDir = 0; + OSStatus os_result = FSPathMakeRef((UInt8*)command_str.c_str(), + &appRef, + &isDir); + if(os_result >= 0) + { + LSApplicationParameters appParams; + memset(&appParams, 0, sizeof(appParams)); + appParams.version = 0; + appParams.flags = kLSLaunchNoParams | kLSLaunchStartClassic; + appParams.application = &appRef; + + if(reportFreeze) + { + // Make sure freeze reporting launches the crash logger synchronously, lest + // Log files get changed by SL while the logger is running. + } + else + { + appParams.flags |= kLSLaunchAsync; + clear_signals(); + } + + ProcessSerialNumber o_psn; + os_result = LSOpenApplication(&appParams, &o_psn); + } + + if(!reportFreeze) + { + _exit(1); + } } std::string LLAppViewerMacOSX::generateSerialNumber() diff --git a/indra/newview/llappviewermacosx.h b/indra/newview/llappviewermacosx.h index 644c2e0551..bddcd31a3e 100644 --- a/indra/newview/llappviewermacosx.h +++ b/indra/newview/llappviewermacosx.h @@ -49,7 +49,8 @@ public: protected: - virtual void handleCrashReporting(); + virtual bool restoreErrorTrap(); + virtual void handleCrashReporting(bool reportFreeze); virtual void handleSyncCrashTrace(); std::string generateSerialNumber(); diff --git a/indra/newview/llappviewerwin32.cpp b/indra/newview/llappviewerwin32.cpp index 06b2a467de..c289daef3c 100644 --- a/indra/newview/llappviewerwin32.cpp +++ b/indra/newview/llappviewerwin32.cpp @@ -85,6 +85,7 @@ LONG WINAPI viewer_windows_exception_handler(struct _EXCEPTION_POINTERS *excepti // Translate the signals/exceptions into cross-platform stuff // Windows implementation + _tprintf( _T("Entering Windows Exception Handler...\n") ); llinfos << "Entering Windows Exception Handler..." << llendl; // Make sure the user sees something to indicate that the app crashed. @@ -92,7 +93,9 @@ LONG WINAPI viewer_windows_exception_handler(struct _EXCEPTION_POINTERS *excepti if (LLApp::isError()) { + _tprintf( _T("Got another fatal signal while in the error handler, die now!\n") ); llwarns << "Got another fatal signal while in the error handler, die now!" << llendl; + retval = EXCEPTION_EXECUTE_HANDLER; return retval; } @@ -121,7 +124,28 @@ LONG WINAPI viewer_windows_exception_handler(struct _EXCEPTION_POINTERS *excepti return retval; } +// Create app mutex creates a unique global windows object. +// If the object can be created it returns true, otherwise +// it returns false. The false result can be used to determine +// if another instance of a second life app (this vers. or later) +// is running. +// *NOTE: Do not use this method to run a single instance of the app. +// This is intended to help debug problems with the cross-platform +// locked file method used for that purpose. +bool create_app_mutex() +{ + bool result = true; + LPCWSTR unique_mutex_name = L"SecondLifeAppMutex"; + HANDLE hMutex; + hMutex = CreateMutex(NULL, TRUE, unique_mutex_name); + if(GetLastError() == ERROR_ALREADY_EXISTS) + { + result = false; + } + return result; +} +//#define DEBUGGING_SEH_FILTER 1 #if DEBUGGING_SEH_FILTER # define WINMAIN DebuggingWinMain #else @@ -148,6 +172,10 @@ int APIENTRY WINMAIN(HINSTANCE hInstance, viewer_app_ptr->setErrorHandler(LLAppViewer::handleViewerCrash); + // Set a debug info flag to indicate if multiple instances are running. + bool found_other_instance = !create_app_mutex(); + gDebugInfo["FoundOtherInstanceAtStartup"] = LLSD::Boolean(found_other_instance); + bool ok = viewer_app_ptr->init(); if(!ok) { @@ -197,6 +225,16 @@ int APIENTRY WINMAIN(HINSTANCE hInstance, } delete viewer_app_ptr; viewer_app_ptr = NULL; + + //start updater + if(LLAppViewer::sUpdaterInfo) + { + _spawnl(_P_NOWAIT, LLAppViewer::sUpdaterInfo->mUpdateExePath.c_str(), LLAppViewer::sUpdaterInfo->mUpdateExePath.c_str(), LLAppViewer::sUpdaterInfo->mParams.str().c_str(), NULL); + + delete LLAppViewer::sUpdaterInfo ; + LLAppViewer::sUpdaterInfo = NULL ; + } + return 0; } @@ -326,6 +364,17 @@ bool LLAppViewerWin32::cleanup() return result; } +bool LLAppViewerWin32::initLogging() +{ + // Remove the crash stack log from previous executions. + // Since we've started logging a new instance of the app, we can assume + // *NOTE: This should happen before the we send a 'previous instance froze' + // crash report, but it must happen after we initialize the DirUtil. + LLWinDebug::clearCrashStacks(); + + return LLAppViewer::initLogging(); +} + void LLAppViewerWin32::initConsole() { // pop up debug console @@ -407,7 +456,7 @@ bool LLAppViewerWin32::initHardwareTest() LLSplashScreen::update(splash_msg.str()); } - if (!LLWinDebug::checkExceptionHandler()) + if (!restoreErrorTrap()) { LL_WARNS("AppInit") << " Someone took over my exception handler (post hardware probe)!" << LL_ENDL; } @@ -447,36 +496,39 @@ bool LLAppViewerWin32::initParseCommandLine(LLCommandLineParser& clp) return true; } +bool LLAppViewerWin32::restoreErrorTrap() +{ + return LLWinDebug::checkExceptionHandler(); +} + void LLAppViewerWin32::handleSyncCrashTrace() { // do nothing } -void LLAppViewerWin32::handleCrashReporting() +void LLAppViewerWin32::handleCrashReporting(bool reportFreeze) { - // Windows only behaivor. Spawn win crash reporter. - std::string exe_path = gDirUtilp->getAppRODataDir(); + const char* logger_name = "win_crash_logger.exe"; + std::string exe_path = gDirUtilp->getExecutableDir(); exe_path += gDirUtilp->getDirDelimiter(); - exe_path += "win_crash_logger.exe"; + exe_path += logger_name; - std::string arg_string = "-user "; - arg_string += LLViewerLogin::getInstance()->getGridLabel(); - - S32 cb = gCrashSettings.getS32(CRASH_BEHAVIOR_SETTING); - switch(cb) + const char* arg_str = logger_name; + + // *NOTE:Mani - win_crash_logger.exe no longer parses command line options. + if(reportFreeze) + { + // Spawn crash logger. + // NEEDS to wait until completion, otherwise log files will get smashed. + _spawnl(_P_WAIT, exe_path.c_str(), arg_str, NULL); + } + else { - case CRASH_BEHAVIOR_ASK: - default: - arg_string += " -dialog "; - _spawnl(_P_NOWAIT, exe_path.c_str(), exe_path.c_str(), arg_string.c_str(), NULL); - break; - - case CRASH_BEHAVIOR_ALWAYS_SEND: - _spawnl(_P_NOWAIT, exe_path.c_str(), exe_path.c_str(), arg_string.c_str(), NULL); - break; - - case CRASH_BEHAVIOR_NEVER_SEND: - break; + S32 cb = gCrashSettings.getS32(CRASH_BEHAVIOR_SETTING); + if(cb != CRASH_BEHAVIOR_NEVER_SEND) + { + _spawnl(_P_NOWAIT, exe_path.c_str(), arg_str, NULL); + } } } diff --git a/indra/newview/llappviewerwin32.h b/indra/newview/llappviewerwin32.h index 5f26a18263..4830c23125 100644 --- a/indra/newview/llappviewerwin32.h +++ b/indra/newview/llappviewerwin32.h @@ -49,11 +49,13 @@ public: virtual bool cleanup(); protected: + virtual bool initLogging(); // Override to clean stack_trace info. virtual void initConsole(); // Initialize OS level debugging console. virtual bool initHardwareTest(); // Win32 uses DX9 to test hardware. virtual bool initParseCommandLine(LLCommandLineParser& clp); - virtual void handleCrashReporting(); + virtual bool restoreErrorTrap(); + virtual void handleCrashReporting(bool reportFreeze); virtual void handleSyncCrashTrace(); virtual bool sendURLToOtherInstance(const std::string& url); diff --git a/indra/newview/llcompilequeue.cpp b/indra/newview/llcompilequeue.cpp index d3041c6206..e9dbc69bce 100644 --- a/indra/newview/llcompilequeue.cpp +++ b/indra/newview/llcompilequeue.cpp @@ -60,6 +60,8 @@ #include "llviewerstats.h" #include "lluictrlfactory.h" +#include "llselectmgr.h" + ///---------------------------------------------------------------------------- /// Local function declarations, constants, enums, and typedefs ///---------------------------------------------------------------------------- @@ -194,7 +196,20 @@ BOOL LLFloaterScriptQueue::start() { //llinfos << "LLFloaterCompileQueue::start()" << llendl; std::string buffer; - buffer = llformat("Starting %s of %d items.", mStartString.c_str(), mObjectIDs.count()); // *TODO: Translate + + LLSelectMgr *mgr = LLSelectMgr::getInstance(); + LLObjectSelectionHandle selectHandle = mgr->getSelection(); + U32 n_objects = 0; + if (gSavedSettings.getBOOL("EditLinkedParts")) + { + n_objects = selectHandle->getObjectCount(); + } + else + { + n_objects = selectHandle->getRootObjectCount(); + } + + buffer = llformat("Starting %s of %d items.", mStartString.c_str(), n_objects); // *TODO: Translate LLScrollListCtrl* list = getChild("queue output"); list->addCommentText(buffer); diff --git a/indra/newview/lldrawpoolbump.cpp b/indra/newview/lldrawpoolbump.cpp index ccf130be7a..d08e82301b 100644 --- a/indra/newview/lldrawpoolbump.cpp +++ b/indra/newview/lldrawpoolbump.cpp @@ -445,7 +445,6 @@ void LLDrawPoolBump::endShiny(bool invisible) gGL.getTexUnit(cube_channel)->setTextureBlendType(LLTexUnit::TB_MULT); } } - gGL.getTexUnit(diffuse_channel)->disable(); gGL.getTexUnit(cube_channel)->disable(); diff --git a/indra/newview/llfeaturemanager.cpp b/indra/newview/llfeaturemanager.cpp index b43838a3a4..3afbdae924 100644 --- a/indra/newview/llfeaturemanager.cpp +++ b/indra/newview/llfeaturemanager.cpp @@ -29,11 +29,11 @@ * $/LicenseInfo$ */ +#include "llviewerprecompiledheaders.h" + #include #include -#include "llviewerprecompiledheaders.h" - #include #include "llfeaturemanager.h" diff --git a/indra/newview/llfloaterinspect.cpp b/indra/newview/llfloaterinspect.cpp index 16c26ac588..a2054cb70b 100644 --- a/indra/newview/llfloaterinspect.cpp +++ b/indra/newview/llfloaterinspect.cpp @@ -206,8 +206,8 @@ void LLFloaterInspect::refresh() mObjectList->operateOnAll(LLScrollListCtrl::OP_DELETE); //List all transient objects, then all linked objects - for (LLObjectSelection::iterator iter = mObjectSelection->begin(); - iter != mObjectSelection->end(); iter++) + for (LLObjectSelection::valid_iterator iter = mObjectSelection->valid_begin(); + iter != mObjectSelection->valid_end(); iter++) { LLSelectNode* obj = *iter; LLSD row; diff --git a/indra/newview/llfloaterpostcard.cpp b/indra/newview/llfloaterpostcard.cpp index 3e12c2e47c..3182568fe8 100644 --- a/indra/newview/llfloaterpostcard.cpp +++ b/indra/newview/llfloaterpostcard.cpp @@ -245,7 +245,7 @@ void LLFloaterPostcard::onClickSend(void* data) std::string from(self->childGetValue("from_form").asString()); std::string to(self->childGetValue("to_form").asString()); - boost::regex emailFormat("[A-Za-z0-9.%+-_]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,}"); + boost::regex emailFormat("[A-Za-z0-9.%+-_]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,}(,[ \t]*[A-Za-z0-9.%+-_]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,})*"); if (to.empty() || !boost::regex_match(to, emailFormat)) { diff --git a/indra/newview/llfloatersnapshot.cpp b/indra/newview/llfloatersnapshot.cpp index db2ea7f41a..dcfb1e9442 100644 --- a/indra/newview/llfloatersnapshot.cpp +++ b/indra/newview/llfloatersnapshot.cpp @@ -899,6 +899,13 @@ void LLSnapshotLivePreview::getSize(S32& w, S32& h) const LLFloaterPostcard* LLSnapshotLivePreview::savePostcard() { + if(mViewerImage[mCurImageIndex].isNull()) + { + //this should never happen!! + llwarns << "The snapshot image has not been generated!" << llendl ; + return NULL ; + } + // calculate and pass in image scale in case image data only use portion // of viewerimage buffer LLVector2 image_scale(1.f, 1.f); @@ -914,9 +921,10 @@ LLFloaterPostcard* LLSnapshotLivePreview::savePostcard() return NULL; } LLFloaterPostcard* floater = LLFloaterPostcard::showFromSnapshot(jpg, mViewerImage[mCurImageIndex], image_scale, mPosTakenGlobal); - // relinquish lifetime of viewerimage and jpeg image to postcard floater - mViewerImage[mCurImageIndex] = NULL; + // relinquish lifetime of jpeg image to postcard floater mFormattedImage = NULL; + mDataSize = 0; + updateSnapshot(FALSE, FALSE); return floater; } @@ -963,11 +971,19 @@ void LLSnapshotLivePreview::saveTexture() } LLViewerStats::getInstance()->incStat(LLViewerStats::ST_SNAPSHOT_COUNT ); + + mDataSize = 0; } BOOL LLSnapshotLivePreview::saveLocal() { BOOL success = gViewerWindow->saveImageNumbered(mFormattedImage); + + // Relinquish image memory. Save button will be disabled as a side-effect. + mFormattedImage = NULL; + mDataSize = 0; + updateSnapshot(FALSE, FALSE); + if(success) { gViewerWindow->playSnapshotAnimAndSound(); @@ -1247,14 +1263,14 @@ void LLFloaterSnapshot::Impl::updateControls(LLFloaterSnapshot* floater) BOOL got_bytes = previewp && previewp->getDataSize() > 0; BOOL got_snap = previewp->getSnapshotUpToDate(); - floater->childSetEnabled("send_btn", shot_type == LLSnapshotLivePreview::SNAPSHOT_POSTCARD && got_bytes && got_snap && previewp->getDataSize() <= MAX_POSTCARD_DATASIZE); - floater->childSetEnabled("upload_btn", shot_type == LLSnapshotLivePreview::SNAPSHOT_TEXTURE && got_bytes && got_snap); - floater->childSetEnabled("save_btn", shot_type == LLSnapshotLivePreview::SNAPSHOT_LOCAL && got_bytes && got_snap); + floater->childSetEnabled("send_btn", shot_type == LLSnapshotLivePreview::SNAPSHOT_POSTCARD && got_snap && previewp->getDataSize() <= MAX_POSTCARD_DATASIZE); + floater->childSetEnabled("upload_btn", shot_type == LLSnapshotLivePreview::SNAPSHOT_TEXTURE && got_snap); + floater->childSetEnabled("save_btn", shot_type == LLSnapshotLivePreview::SNAPSHOT_LOCAL && got_snap); LLLocale locale(LLLocale::USER_LOCALE); std::string bytes_string; LLResMgr::getInstance()->getIntegerString(bytes_string, (previewp->getDataSize()) >> 10 ); - floater->childSetTextArg("file_size_label", "[SIZE]", got_snap ? bytes_string : got_bytes ? floater->getString("unknown") : std::string("???")); + floater->childSetTextArg("file_size_label", "[SIZE]", got_snap ? bytes_string : floater->getString("unknown")); floater->childSetColor("file_size_label", shot_type == LLSnapshotLivePreview::SNAPSHOT_POSTCARD && got_bytes @@ -1384,6 +1400,8 @@ void LLFloaterSnapshot::Impl::onClickKeep(void* data) { checkAutoSnapshot(previewp); } + + updateControls(view); } } @@ -1638,6 +1656,9 @@ void LLFloaterSnapshot::Impl::updateResolution(LLUICtrl* ctrl, void* data, BOOL LLSnapshotLivePreview* previewp = getPreviewView(view); if (previewp && combobox->getCurrentIndex() >= 0) { + S32 original_width = 0 , original_height = 0 ; + previewp->getSize(original_width, original_height) ; + if (width == 0 || height == 0) { // take resolution from current window size @@ -1662,12 +1683,17 @@ void LLFloaterSnapshot::Impl::updateResolution(LLUICtrl* ctrl, void* data, BOOL { resetSnapshotSizeOnUI(view, width, height) ; } - previewp->setSize(width, height); - + if(view->childGetValue("snapshot_width").asInteger() != width || view->childGetValue("snapshot_height").asInteger() != height) { view->childSetValue("snapshot_width", width); view->childSetValue("snapshot_height", height); + } + + if(original_width != width || original_height != height) + { + previewp->setSize(width, height); + // hide old preview as the aspect ratio could be wrong checkAutoSnapshot(previewp, FALSE); getPreviewView(view)->updateSnapshot(FALSE, TRUE); diff --git a/indra/newview/llfloatertopobjects.cpp b/indra/newview/llfloatertopobjects.cpp index 617d4d010f..eea6b40cba 100644 --- a/indra/newview/llfloatertopobjects.cpp +++ b/indra/newview/llfloatertopobjects.cpp @@ -212,7 +212,7 @@ void LLFloaterTopObjects::handleReply(LLMessageSystem *msg, void** data) if (mCurrentMode == STAT_REPORT_TOP_SCRIPTS && have_extended_data) { - element["columns"][5]["column"] = "Mono Time"; + element["columns"][5]["column"] = "mono_time"; element["columns"][5]["value"] = llformat("%0.3f", mono_score); element["columns"][5]["font"] = "SANSSERIF"; } @@ -238,6 +238,7 @@ void LLFloaterTopObjects::handleReply(LLMessageSystem *msg, void** data) { setTitle(getString("top_scripts_title")); list->setColumnLabel("score", getString("scripts_score_label")); + list->setColumnLabel("mono_time", getString("scripts_mono_time_label")); LLUIString format = getString("top_scripts_text"); format.setArg("[COUNT]", llformat("%d", total_count)); @@ -248,6 +249,7 @@ void LLFloaterTopObjects::handleReply(LLMessageSystem *msg, void** data) { setTitle(getString("top_colliders_title")); list->setColumnLabel("score", getString("colliders_score_label")); + list->setColumnLabel("mono_time", ""); LLUIString format = getString("top_colliders_text"); format.setArg("[COUNT]", llformat("%d", total_count)); childSetValue("title_text", LLSD(format)); diff --git a/indra/newview/llinventorymodel.cpp b/indra/newview/llinventorymodel.cpp index b56629b60a..d46006f7dd 100644 --- a/indra/newview/llinventorymodel.cpp +++ b/indra/newview/llinventorymodel.cpp @@ -1499,7 +1499,7 @@ void LLInventoryModel::stopBackgroundFetch() //static void LLInventoryModel::backgroundFetch(void*) { - if (sBackgroundFetchActive) + if (sBackgroundFetchActive && gAgent.getRegion()) { //If we'll be using the capability, we'll be sending batches and the background thing isn't as important. std::string url = gAgent.getRegion()->getCapability("WebFetchInventoryDescendents"); diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index 7b7bdfd582..81decdf40a 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -5940,9 +5940,9 @@ S32 LLObjectSelection::getRootObjectCount() return count; } -bool LLObjectSelection::applyToObjects(LLSelectedObjectFunctor* func, bool firstonly) +bool LLObjectSelection::applyToObjects(LLSelectedObjectFunctor* func) { - bool result = firstonly ? false : true; + bool result = true; for (iterator iter = begin(); iter != end(); ) { iterator nextiter = iter++; @@ -5950,10 +5950,7 @@ bool LLObjectSelection::applyToObjects(LLSelectedObjectFunctor* func, bool first if (!object) continue; bool r = func->apply(object); - if (firstonly && r) - return true; - else - result = result && r; + result = result && r; } return result; } diff --git a/indra/newview/llselectmgr.h b/indra/newview/llselectmgr.h index ecd065fdf8..f210fdb9d3 100644 --- a/indra/newview/llselectmgr.h +++ b/indra/newview/llselectmgr.h @@ -316,7 +316,7 @@ public: // If firstonly is FALSE, returns the AND of all apply() calls. // Else returns TRUE immediately if any apply() call succeeds (i.e. OR with early exit) bool applyToRootObjects(LLSelectedObjectFunctor* func, bool firstonly = false); - bool applyToObjects(LLSelectedObjectFunctor* func, bool firstonly = false); + bool applyToObjects(LLSelectedObjectFunctor* func); bool applyToTEs(LLSelectedTEFunctor* func, bool firstonly = false); bool applyToRootNodes(LLSelectedNodeFunctor* func, bool firstonly = false); bool applyToNodes(LLSelectedNodeFunctor* func, bool firstonly = false); diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index 59bf29161e..18b3cb856e 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -117,11 +117,15 @@ void validate_drawable(LLDrawable* drawablep) S32 AABBSphereIntersect(const LLVector3& min, const LLVector3& max, const LLVector3 &origin, const F32 &rad) +{ + return AABBSphereIntersectR2(min, max, origin, rad*rad); +} + +S32 AABBSphereIntersectR2(const LLVector3& min, const LLVector3& max, const LLVector3 &origin, const F32 &r) { F32 d = 0.f; F32 t; - F32 r = rad*rad; - + if ((min-origin).magVecSquared() < r && (max-origin).magVecSquared() < r) { diff --git a/indra/newview/llspatialpartition.h b/indra/newview/llspatialpartition.h index 2d9900da1b..1fa24d2115 100644 --- a/indra/newview/llspatialpartition.h +++ b/indra/newview/llspatialpartition.h @@ -52,6 +52,7 @@ class LLSpatialBridge; class LLSpatialGroup; S32 AABBSphereIntersect(const LLVector3& min, const LLVector3& max, const LLVector3 &origin, const F32 &rad); +S32 AABBSphereIntersectR2(const LLVector3& min, const LLVector3& max, const LLVector3 &origin, const F32 &radius_squared); class LLDrawInfo : public LLRefCount { diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index 3de0cf80ce..9a6454be33 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -2516,7 +2516,7 @@ bool idle_startup() gDebugView->mFastTimerView->setVisible(TRUE); #endif - LLAppViewer::instance()->initMainloopTimeout("Mainloop Init"); + LLAppViewer::instance()->handleLoginComplete(); return TRUE; } @@ -2832,7 +2832,6 @@ void update_app(BOOL mandatory, const std::string& auth_msg) void update_dialog_callback(S32 option, void *userdata) { - std::string update_exe_path; bool mandatory = userdata != NULL; #if !LL_RELEASE_FOR_DOWNLOAD @@ -2875,29 +2874,41 @@ void update_dialog_callback(S32 option, void *userdata) // *TODO constantize this guy LLURI update_url = LLURI::buildHTTP("secondlife.com", 80, "update.php", query_map); + if(LLAppViewer::sUpdaterInfo) + { + delete LLAppViewer::sUpdaterInfo ; + } + LLAppViewer::sUpdaterInfo = new LLAppViewer::LLUpdaterInfo() ; + #if LL_WINDOWS - update_exe_path = gDirUtilp->getTempFilename(); - if (update_exe_path.empty()) + LLAppViewer::sUpdaterInfo->mUpdateExePath = gDirUtilp->getTempFilename(); + if (LLAppViewer::sUpdaterInfo->mUpdateExePath.empty()) { + delete LLAppViewer::sUpdaterInfo ; + LLAppViewer::sUpdaterInfo = NULL ; + // We're hosed, bail LL_WARNS("AppInit") << "LLDir::getTempFilename() failed" << LL_ENDL; LLAppViewer::instance()->forceQuit(); return; } - update_exe_path += ".exe"; + LLAppViewer::sUpdaterInfo->mUpdateExePath += ".exe"; std::string updater_source = gDirUtilp->getAppRODataDir(); updater_source += gDirUtilp->getDirDelimiter(); updater_source += "updater.exe"; LL_DEBUGS("AppInit") << "Calling CopyFile source: " << updater_source - << " dest: " << update_exe_path + << " dest: " << LLAppViewer::sUpdaterInfo->mUpdateExePath << LL_ENDL; - if (!CopyFileA(updater_source.c_str(), update_exe_path.c_str(), FALSE)) + if (!CopyFileA(updater_source.c_str(), LLAppViewer::sUpdaterInfo->mUpdateExePath.c_str(), FALSE)) { + delete LLAppViewer::sUpdaterInfo ; + LLAppViewer::sUpdaterInfo = NULL ; + LL_WARNS("AppInit") << "Unable to copy the updater!" << LL_ENDL; LLAppViewer::instance()->forceQuit(); return; @@ -2910,18 +2921,13 @@ void update_dialog_callback(S32 option, void *userdata) gSavedSettings.setString( "NextLoginLocation", LLURLSimString::sInstance.mSimString ); }; - std::ostringstream params; - params << "-url \"" << update_url.asString() << "\""; + LLAppViewer::sUpdaterInfo->mParams << "-url \"" << update_url.asString() << "\""; - LL_DEBUGS("AppInit") << "Calling updater: " << update_exe_path << " " << params.str() << LL_ENDL; + LL_DEBUGS("AppInit") << "Calling updater: " << LLAppViewer::sUpdaterInfo->mUpdateExePath << " " << LLAppViewer::sUpdaterInfo->mParams.str() << LL_ENDL; //Explicitly remove the marker file, otherwise we pass the lock onto the child process and things get weird. LLAppViewer::instance()->removeMarkerFile(); // In case updater fails - // Use spawn() to run asynchronously - int retval = _spawnl(_P_NOWAIT, update_exe_path.c_str(), update_exe_path.c_str(), params.str().c_str(), NULL); - LL_DEBUGS("AppInit") << "Spawn returned " << retval << LL_ENDL; - #elif LL_DARWIN // if a sim name was passed in via command line parameter (typically through a SLURL) if ( LLURLSimString::sInstance.mSimString.length() ) @@ -2930,19 +2936,19 @@ void update_dialog_callback(S32 option, void *userdata) gSavedSettings.setString( "NextLoginLocation", LLURLSimString::sInstance.mSimString ); }; - update_exe_path = "'"; - update_exe_path += gDirUtilp->getAppRODataDir(); - update_exe_path += "/mac-updater.app/Contents/MacOS/mac-updater' -url \""; - update_exe_path += update_url.asString(); - update_exe_path += "\" -name \""; - update_exe_path += LLAppViewer::instance()->getSecondLifeTitle(); - update_exe_path += "\" &"; - - LL_DEBUGS("AppInit") << "Calling updater: " << update_exe_path << LL_ENDL; - + LLAppViewer::sUpdaterInfo->mUpdateExePath = "'"; + LLAppViewer::sUpdaterInfo->mUpdateExePath += gDirUtilp->getAppRODataDir(); + LLAppViewer::sUpdaterInfo->mUpdateExePath += "/mac-updater.app/Contents/MacOS/mac-updater' -url \""; + LLAppViewer::sUpdaterInfo->mUpdateExePath += update_url.asString(); + LLAppViewer::sUpdaterInfo->mUpdateExePath += "\" -name \""; + LLAppViewer::sUpdaterInfo->mUpdateExePath += LLAppViewer::instance()->getSecondLifeTitle(); + LLAppViewer::sUpdaterInfo->mUpdateExePath += "\" &"; + + LL_DEBUGS("AppInit") << "Calling updater: " << LLAppViewer::sUpdaterInfo->mUpdateExePath << LL_ENDL; + // Run the auto-updater. - system(update_exe_path.c_str()); /* Flawfinder: ignore */ - + system(LLAppViewer::sUpdaterInfo->mUpdateExePath.c_str()); /* Flawfinder: ignore */ + #elif LL_LINUX OSMessageBox("Automatic updating is not yet implemented for Linux.\n" "Please download the latest version from www.secondlife.com.", diff --git a/indra/newview/llstartup.h b/indra/newview/llstartup.h index 3cfe1ca97f..1639ed55b6 100644 --- a/indra/newview/llstartup.h +++ b/indra/newview/llstartup.h @@ -87,6 +87,7 @@ public: // Always use this to set gStartupState so changes are logged static void setStartupState( EStartupState state ); static EStartupState getStartupState() { return gStartupState; }; + static std::string getStartupStateString() { return startupStateToString(gStartupState); }; static void multimediaInit(); // Initialize LLViewerMedia multimedia engine. diff --git a/indra/newview/lltexlayer.cpp b/indra/newview/lltexlayer.cpp index 158bae00b8..5f56318d83 100644 --- a/indra/newview/lltexlayer.cpp +++ b/indra/newview/lltexlayer.cpp @@ -60,8 +60,6 @@ // SJB: We really always want to use the GL cache; // let GL page textures in and out of video RAM instead of trying to do so by hand. -LLGradientPaletteList gGradientPaletteList; - // static S32 LLTexLayerSetBuffer::sGLByteCount = 0; S32 LLTexLayerSetBuffer::sGLBumpByteCount = 0; @@ -1796,8 +1794,6 @@ BOOL LLTexLayerParamAlphaInfo::parseXml(LLXmlTreeNode* node) static LLStdStringHandle domain_string = LLXmlTree::addAttributeString("domain"); param_alpha_node->getFastAttributeF32( domain_string, mDomain ); - gGradientPaletteList.initPalette(mDomain); - return TRUE; } @@ -1992,7 +1988,7 @@ BOOL LLTexLayerParamAlpha::render( S32 x, S32 y, S32 width, S32 height ) if( !mCachedProcessedImageGL || (mCachedProcessedImageGL->getWidth() != image_tga_width) || (mCachedProcessedImageGL->getHeight() != image_tga_height) || - (weight_changed && !(gGLManager.mHasPalettedTextures && gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_PALETTE))) ) + (weight_changed )) { // llinfos << "Building Cached Alpha: " << mName << ": (" << mStaticImageRaw->getWidth() << ", " << mStaticImageRaw->getHeight() << ") " << effective_weight << llendl; mCachedEffectiveWeight = effective_weight; @@ -2004,32 +2000,15 @@ BOOL LLTexLayerParamAlpha::render( S32 x, S32 y, S32 width, S32 height ) // We now have something in one of our caches LLTexLayerSet::sHasCaches |= mCachedProcessedImageGL ? TRUE : FALSE; - if (gGLManager.mHasPalettedTextures && gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_PALETTE)) - { - // interpret luminance values as color index table - mCachedProcessedImageGL->setExplicitFormat( GL_COLOR_INDEX8_EXT, GL_COLOR_INDEX ); - } - else - { - mCachedProcessedImageGL->setExplicitFormat( GL_ALPHA8, GL_ALPHA ); - } + + mCachedProcessedImageGL->setExplicitFormat( GL_ALPHA8, GL_ALPHA ); } // Applies domain and effective weight to data as it is decoded. Also resizes the raw image if needed. - if (gGLManager.mHasPalettedTextures && gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_PALETTE)) - { - mStaticImageRaw = NULL; - mStaticImageRaw = new LLImageRaw; - mStaticImageTGA->decode(mStaticImageRaw); - mNeedsCreateTexture = TRUE; - } - else - { - mStaticImageRaw = NULL; - mStaticImageRaw = new LLImageRaw; - mStaticImageTGA->decodeAndProcess( mStaticImageRaw, getInfo()->mDomain, effective_weight ); - mNeedsCreateTexture = TRUE; - } + mStaticImageRaw = NULL; + mStaticImageRaw = new LLImageRaw; + mStaticImageTGA->decodeAndProcess( mStaticImageRaw, getInfo()->mDomain, effective_weight ); + mNeedsCreateTexture = TRUE; } if( mCachedProcessedImageGL ) @@ -2047,10 +2026,6 @@ BOOL LLTexLayerParamAlpha::render( S32 x, S32 y, S32 width, S32 height ) LLGLSNoAlphaTest gls_no_alpha_test; gGL.getTexUnit(0)->bind(mCachedProcessedImageGL); - if (gGLManager.mHasPalettedTextures && gPipeline.hasRenderDebugFeatureMask(LLPipeline::RENDER_DEBUG_FEATURE_PALETTE)) - { - gGradientPaletteList.setHardwarePalette( getInfo()->mDomain, effective_weight ); - } gl_rect_2d_simple_tex( width, height ); gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); stop_glerror(); @@ -2540,68 +2515,3 @@ LLMaskedMorph::LLMaskedMorph( LLPolyMorphTarget *morph_target, BOOL invert ) : m morph_target->addPendingMorphMask(); } - -//----------------------------------------------------------------------------- -// LLGradientPaletteList -//----------------------------------------------------------------------------- - -LLGradientPaletteList::~LLGradientPaletteList() -{ - // Note: can't just call deleteAllData() because the data values are arrays. - for( palette_map_t::iterator iter = mPaletteMap.begin(); - iter != mPaletteMap.end(); iter++ ) - { - U8* data = iter->second; - delete []data; - } -} - -void LLGradientPaletteList::initPalette(F32 domain) -{ - palette_map_t::iterator iter = mPaletteMap.find( domain ); - if( iter == mPaletteMap.end() ) - { - U8 *palette = new U8[512 * 4]; - mPaletteMap[domain] = palette; - S32 ramp_start = 255 - llfloor(domain * 255.f); - S32 ramp_end = 255; - F32 ramp_factor = (ramp_end == ramp_start) ? 0.f : (255.f / ((F32)ramp_end - (F32)ramp_start)); - - // *TODO: move conditionals outside of loop, since this really - // is just a sequential process. - for (S32 i = 0; i < 512; i++) - { - palette[(i * 4) + 1] = 0; - palette[(i * 4) + 2] = 0; - if (i <= ramp_start) - { - palette[(i * 4)] = 0; - palette[(i * 4) + 3] = 0; - } - else if (i < ramp_end) - { - palette[(i * 4)] = llfloor(((F32)i - (F32)ramp_start) * ramp_factor); - palette[(i * 4) + 3] = llfloor(((F32)i - (F32)ramp_start) * ramp_factor); - } - else - { - palette[(i * 4)] = 255; - palette[(i * 4) + 3] = 255; - } - } - } -} - -void LLGradientPaletteList::setHardwarePalette( F32 domain, F32 effective_weight ) -{ - palette_map_t::iterator iter = mPaletteMap.find( domain ); - if( iter != mPaletteMap.end() ) - { - U8* palette = iter->second; - set_palette( palette + llfloor(effective_weight * (255.f * (1.f - domain))) * 4); - } - else - { - llwarns << "LLGradientPaletteList::setHardwarePalette() missing domain " << domain << llendl; - } -} diff --git a/indra/newview/lltexlayer.h b/indra/newview/lltexlayer.h index 992e392fc7..3fb6b50977 100644 --- a/indra/newview/lltexlayer.h +++ b/indra/newview/lltexlayer.h @@ -527,41 +527,6 @@ public: }; -//----------------------------------------------------------------------------- -// LLGradientPaletteList -// A static set of ramp grayscale palettes. The "effective_weight" is used -// to determine the x position of the ramp (offset) -// -// "Domain" isn't really the right word. It refers to the width of the -// ramp portion of the function that relates input and output pixel values. -// A domain of 0 gives a step function. -// -// | /---------------- -// O| / | -// u| / | -// t| / | -// p|------------------/ | -// u| | | -// t|<---------------->|<-->| -// | "offset" "domain" -// | -// --+---Input-------------------------------- -// | -//----------------------------------------------------------------------------- -class LLGradientPaletteList -{ -public: - LLGradientPaletteList() {} - ~LLGradientPaletteList(); - - void initPalette(F32 domain); - void setHardwarePalette(F32 domain, F32 effective_weight); - -private: - typedef std::map palette_map_t; - palette_map_t mPaletteMap; -}; - // Used by LLTexLayerSetBuffer for a callback. class LLBakedUploadData { diff --git a/indra/newview/llurlhistory.cpp b/indra/newview/llurlhistory.cpp index 902ab88688..6c0ef01c81 100644 --- a/indra/newview/llurlhistory.cpp +++ b/indra/newview/llurlhistory.cpp @@ -72,9 +72,16 @@ bool LLURLHistory::loadFile(const std::string& filename) // static bool LLURLHistory::saveFile(const std::string& filename) -{ - std::string temp_str = gDirUtilp->getLindenUserDir() + gDirUtilp->getDirDelimiter(); - llofstream out((temp_str + filename)); +{ + std::string temp_str = gDirUtilp->getLindenUserDir(); + if( temp_str.empty() ) + { + llwarns << "Can't save. No user directory set." << llendl; + return false; + } + + temp_str += gDirUtilp->getDirDelimiter() + filename; + llofstream out(temp_str); if (!out.good()) { llwarns << "Unable to open " << filename << " for output." << llendl; diff --git a/indra/newview/llviewerassetstorage.cpp b/indra/newview/llviewerassetstorage.cpp index 0363dba631..b6d54d9789 100644 --- a/indra/newview/llviewerassetstorage.cpp +++ b/indra/newview/llviewerassetstorage.cpp @@ -29,9 +29,9 @@ * $/LicenseInfo$ */ +#include "llviewerprecompiledheaders.h" #include "linden_common.h" -#include "llviewerprecompiledheaders.h" #include "llagent.h" #include "llviewerassetstorage.h" diff --git a/indra/newview/llviewerdisplay.cpp b/indra/newview/llviewerdisplay.cpp index 2f907fddbf..0eb289beed 100644 --- a/indra/newview/llviewerdisplay.cpp +++ b/indra/newview/llviewerdisplay.cpp @@ -113,7 +113,6 @@ void render_ui_3d(); void render_ui_2d(); void render_disconnected_background(); void render_hud_elements(); -void process_keystrokes_async(); void display_startup() { @@ -684,7 +683,7 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); } - LLAppViewer::instance()->pingMainloopTimeout("Display:Render"); + LLAppViewer::instance()->pingMainloopTimeout("Display:RenderStart"); //// render frontmost floater opaque for occlusion culling purposes //LLFloater* frontmost_floaterp = gFloaterView->getFrontmost(); @@ -730,10 +729,13 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT | GL_STENCIL_BUFFER_BIT); gGL.setColorMask(true, false); } - + + LLAppViewer::instance()->pingMainloopTimeout("Display:RenderGeom"); + if (!(LLAppViewer::instance()->logoutRequestSent() && LLAppViewer::instance()->hasSavedFinalSnapshot()) && !gRestoreGL) { + gGL.setColorMask(true, false); LLPipeline::sUnderWaterRender = LLViewerCamera::getInstance()->cameraUnderWater() ? TRUE : FALSE; gPipeline.renderGeom(*LLViewerCamera::getInstance(), TRUE); @@ -748,9 +750,12 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) } stop_glerror(); } + + LLAppViewer::instance()->pingMainloopTimeout("Display:RenderFlush"); if (to_texture) { + gPipeline.mScreen.flush(); } @@ -759,23 +764,20 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) /// Using render to texture would be faster/better, but I don't have a /// grasp of their full display stack just yet. // gPostProcess->apply(gViewerWindow->getWindowDisplayWidth(), gViewerWindow->getWindowDisplayHeight()); - + + LLAppViewer::instance()->pingMainloopTimeout("Display:RenderUI"); + if (!for_snapshot) { + gFrameStats.start(LLFrameStats::RENDER_UI); render_ui(); } LLSpatialGroup::sNoDelete = FALSE; } - gFrameStats.start(LLFrameStats::RENDER_UI); - - if (gHandleKeysAsync) - { - LLAppViewer::instance()->pingMainloopTimeout("Display:Keystrokes"); - process_keystrokes_async(); - stop_glerror(); - } - + + LLAppViewer::instance()->pingMainloopTimeout("Display:FrameStats"); + gFrameStats.start(LLFrameStats::MISC_END); stop_glerror(); @@ -1231,43 +1233,3 @@ void display_cleanup() { gDisconnectedImagep = NULL; } - -void process_keystrokes_async() -{ -#if LL_WINDOWS - MSG msg; - // look through all input messages, leaving them in the event queue - while( PeekMessage(&msg, NULL, 0, 0, PM_NOREMOVE | PM_NOYIELD)) - { - // on first mouse message, break out - if (msg.message >= WM_MOUSEFIRST && - msg.message <= WM_MOUSELAST || - msg.message == WM_QUIT) - { - break; - } - - // this is a message we want to handle now, so remove it from the event queue - PeekMessage(&msg, NULL, msg.message, msg.message, PM_REMOVE | PM_NOYIELD); - // if (msg.message == WM_KEYDOWN) - // { - // llinfos << "Process async key down " << (U32)msg.wParam << llendl; - // } - TranslateMessage(&msg); - DispatchMessage(&msg); - } - - // Scan keyboard for movement keys. Command keys and typing - // are handled by windows callbacks. Don't do this until we're - // done initializing. JC - if (gViewerWindow->mWindow->getVisible() - && gViewerWindow->getActive() - && !gViewerWindow->mWindow->getMinimized() - && LLStartUp::getStartupState() == STATE_STARTED - && !gViewerWindow->getShowProgress() - && !gFocusMgr.focusLocked()) - { - gKeyboard->scanKeyboard(); - } -#endif -} diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp index ea1ef2a6a6..aa78362089 100644 --- a/indra/newview/llviewermedia.cpp +++ b/indra/newview/llviewermedia.cpp @@ -552,6 +552,7 @@ void LLViewerMedia::buildMediaManagerData( LLMediaManagerData* init_data ) // static void LLViewerMedia::cleanupClass() { + stop() ; LLMediaManager::cleanupClass(); } diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp index 6e37e6253f..c8ad7fad97 100644 --- a/indra/newview/llviewermenu.cpp +++ b/indra/newview/llviewermenu.cpp @@ -1023,7 +1023,6 @@ void init_debug_ui_menu(LLMenuGL* menu) menu->append(new LLMenuItemCallGL("Web Browser Test", &handle_web_browser_test)); menu->append(new LLMenuItemCallGL("Buy Currency Test", &handle_buy_currency_test)); menu->append(new LLMenuItemCallGL("Editable UI", &edit_ui)); - menu->append(new LLMenuItemToggleGL("Async Keystrokes", &gHandleKeysAsync)); menu->append(new LLMenuItemCallGL( "Dump SelectMgr", &dump_select_mgr)); menu->append(new LLMenuItemCallGL( "Dump Inventory", &dump_inventory)); menu->append(new LLMenuItemCallGL( "Dump Focus Holder", &handle_dump_focus, NULL, NULL, 'F', MASK_ALT | MASK_CONTROL)); @@ -1154,10 +1153,6 @@ void init_debug_rendering_menu(LLMenuGL* menu) &LLPipeline::toggleRenderDebugFeature, NULL, &LLPipeline::toggleRenderDebugFeatureControl, (void*)LLPipeline::RENDER_DEBUG_FEATURE_FOG, KEY_F6, MASK_ALT|MASK_CONTROL)); - sub_menu->append(new LLMenuItemCheckGL("Palletized Textures", - &LLPipeline::toggleRenderDebugFeature, NULL, - &LLPipeline::toggleRenderDebugFeatureControl, - (void*)LLPipeline::RENDER_DEBUG_FEATURE_PALETTE, KEY_F7, MASK_ALT|MASK_CONTROL)); sub_menu->append(new LLMenuItemCheckGL("Test FRInfo", &LLPipeline::toggleRenderDebugFeature, NULL, &LLPipeline::toggleRenderDebugFeatureControl, @@ -1748,7 +1743,7 @@ class LLViewCommunicate : public view_listener_t { bool handleEvent(LLPointer event, const LLSD& userdata) { - if (LLFloaterChatterBox::getInstance()->getFloaterCount() == 0) + if (LLFloaterChatterBox::getInstance()->getFloaterCount() == 0) { LLFloaterMyFriends::toggleInstance(); } @@ -1756,7 +1751,6 @@ class LLViewCommunicate : public view_listener_t { LLFloaterChatterBox::toggleInstance(); } - return true; } }; @@ -5228,6 +5222,10 @@ class LLFloaterVisible : public view_listener_t { new_value = LLFloaterMyFriends::instanceVisible(0); } + else if (floater_name == "communicate") + { + new_value = LLFloaterChatterBox::instanceVisible(); + } else if (floater_name == "toolbar") { new_value = LLToolBar::visible(NULL); @@ -5264,6 +5262,11 @@ class LLFloaterVisible : public view_listener_t { new_value = LLFloaterBeacons::instanceVisible(LLSD()); } + else if (floater_name == "inventory") + { + LLInventoryView* iv = LLInventoryView::getActiveInventory(); + new_value = (NULL != iv && TRUE == iv->getVisible()); + } gMenuHolder->findControl(control_name)->setValue(new_value); return true; } @@ -5929,10 +5932,10 @@ namespace void queue_actions(LLFloaterScriptQueue* q, const std::string& noscriptmsg, const std::string& nomodmsg) { - // Apply until an object fails QueueObjects func(q); - const bool firstonly = true; - bool fail = LLSelectMgr::getInstance()->getSelection()->applyToObjects(&func, firstonly); + LLSelectMgr *mgr = LLSelectMgr::getInstance(); + LLObjectSelectionHandle selectHandle = mgr->getSelection(); + bool fail = selectHandle->applyToObjects(&func); if(fail) { if ( !func.scripted ) @@ -5957,61 +5960,67 @@ void queue_actions(LLFloaterScriptQueue* q, const std::string& noscriptmsg, cons } } +void handle_compile_queue(std::string to_lang) +{ + LLFloaterCompileQueue* queue; + if (to_lang == "mono") + { + queue = LLFloaterCompileQueue::create(TRUE); + } + else + { + queue = LLFloaterCompileQueue::create(FALSE); + } + queue_actions(queue, "CannotRecompileSelectObjectsNoScripts", "CannotRecompileSelectObjectsNoPermission"); +} + +void handle_reset_selection(void) +{ + LLFloaterResetQueue* queue = LLFloaterResetQueue::create(); + queue_actions(queue, "CannotResetSelectObjectsNoScripts", "CannotResetSelectObjectsNoPermission"); +} + +void handle_set_run_selection(void) +{ + LLFloaterRunQueue* queue = LLFloaterRunQueue::create(); + queue_actions(queue, "CannotSetRunningSelectObjectsNoScripts", "CannotSerRunningSelectObjectsNoPermission"); +} + +void handle_set_not_run_selection(void) +{ + LLFloaterNotRunQueue* queue = LLFloaterNotRunQueue::create(); + queue_actions(queue, "CannotSetRunningNotSelectObjectsNoScripts", "CannotSerRunningNotSelectObjectsNoPermission"); +} + class LLToolsSelectedScriptAction : public view_listener_t { bool handleEvent(LLPointer event, const LLSD& userdata) { std::string action = userdata.asString(); - LLFloaterScriptQueue* queue = NULL; if (action == "compile mono") { - queue = LLFloaterCompileQueue::create(TRUE); + handle_compile_queue("mono"); } if (action == "compile lsl") { - queue = LLFloaterCompileQueue::create(FALSE); + handle_compile_queue("lsl"); } else if (action == "reset") { - queue = LLFloaterResetQueue::create(); + handle_reset_selection(); } else if (action == "start") { - queue = LLFloaterRunQueue::create(); + handle_set_run_selection(); } else if (action == "stop") { - queue = LLFloaterNotRunQueue::create(); + handle_set_not_run_selection(); } - if (!queue) - { - return true; - } - - queue_actions(queue, "CannotRecompileSelectObjectsNoScripts", "CannotRecompileSelectObjectsNoPermission"); - return true; } }; -void handle_reset_selection(void*) -{ - LLFloaterResetQueue* queue = LLFloaterResetQueue::create(); - queue_actions(queue, "CannotResetSelectObjectsNoScripts", "CannotResetSelectObjectsNoPermission"); -} - -void handle_set_run_selection(void*) -{ - LLFloaterRunQueue* queue = LLFloaterRunQueue::create(); - queue_actions(queue, "CannotSetRunningSelectObjectsNoScripts", "CannotSerRunningSelectObjectsNoPermission"); -} - -void handle_set_not_run_selection(void*) -{ - LLFloaterNotRunQueue* queue = LLFloaterNotRunQueue::create(); - queue_actions(queue, "CannotSetRunningNotSelectObjectsNoScripts", "CannotSerRunningNotSelectObjectsNoPermission"); -} - void handle_selected_texture_info(void*) { for (LLObjectSelection::valid_iterator iter = LLSelectMgr::getInstance()->getSelection()->valid_begin(); diff --git a/indra/newview/llviewermenufile.cpp b/indra/newview/llviewermenufile.cpp index 9448a00e68..33c21b4061 100644 --- a/indra/newview/llviewermenufile.cpp +++ b/indra/newview/llviewermenufile.cpp @@ -352,7 +352,8 @@ class LLFileEnableCloseWindow : public view_listener_t { bool handleEvent(LLPointer event, const LLSD& userdata) { - bool new_value = gFloaterView->getFocusedFloater() != NULL || gSnapshotFloaterView->getFocusedFloater() != NULL; + bool new_value = NULL != LLFloater::getClosableFloaterFromFocus(); + // horrendously opaque, this code gMenuHolder->findControl(userdata["control"].asString())->setValue(new_value); return true; @@ -937,6 +938,11 @@ void upload_new_resource(const LLTransactionID &tid, LLAssetType::EType asset_ty LLAssetStorage::LLStoreAssetCallback callback, void *userdata) { + if(gDisconnected) + { + return ; + } + LLAssetID uuid = tid.makeAssetID(gAgent.getSecureSessionID()); if( LLAssetType::AT_SOUND == asset_type ) diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index eeedb98250..e38ef27cf1 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -203,7 +203,7 @@ struct LLFriendshipOffer void give_money(const LLUUID& uuid, LLViewerRegion* region, S32 amount, BOOL is_group, S32 trx_type, const std::string& desc) { - if(0 == amount) return; + if(0 == amount || !region) return; amount = abs(amount); LL_INFOS("Messaging") << "give_money(" << uuid << "," << amount << ")"<< LL_ENDL; if(can_afford_transaction(amount)) diff --git a/indra/newview/llviewerobjectlist.cpp b/indra/newview/llviewerobjectlist.cpp index 1fca77ec50..ef657a17cc 100644 --- a/indra/newview/llviewerobjectlist.cpp +++ b/indra/newview/llviewerobjectlist.cpp @@ -827,8 +827,15 @@ void LLViewerObjectList::removeDrawable(LLDrawable* drawablep) for (S32 i = 0; i < drawablep->getNumFaces(); i++) { - LLViewerObject* objectp = drawablep->getFace(i)->getViewerObject(); - mSelectPickList.erase(objectp); + LLFace* facep = drawablep->getFace(i) ; + if(facep) + { + LLViewerObject* objectp = facep->getViewerObject(); + if(objectp) + { + mSelectPickList.erase(objectp); + } + } } } diff --git a/indra/newview/llviewerstats.cpp b/indra/newview/llviewerstats.cpp index 7d0d16a100..fac01cbc46 100644 --- a/indra/newview/llviewerstats.cpp +++ b/indra/newview/llviewerstats.cpp @@ -759,8 +759,12 @@ void send_stats() // misc["string_2"] = // misc["int_1"] = LLFloaterDirectory::sOldSearchCount; // Steve: 1.18.6 // misc["int_2"] = LLFloaterDirectory::sNewSearchCount; // Steve: 1.18.6 - misc["int_1"] = LLSD::Integer(gSavedSettings.getU32("RenderQualityPerformance")); // Steve: 1.21 - misc["int_2"] = LLSD::Integer(gFrameStalls); // Steve: 1.21 +// misc["int_1"] = LLSD::Integer(gSavedSettings.getU32("RenderQualityPerformance")); // Steve: 1.21 +// misc["int_2"] = LLSD::Integer(gFrameStalls); // Steve: 1.21 + F32 unbaked_time = LLVOAvatar::sUnbakedTime / gFrameTime; + misc["int_1"] = LLSD::Integer(unbaked_time * 1000.f); // Steve: 1.22 + F32 grey_time = LLVOAvatar::sGreyTime / gFrameTime; + misc["int_2"] = LLSD::Integer(grey_time * 1000.f); // Steve: 1.22 LLViewerStats::getInstance()->addToMessage(body); diff --git a/indra/newview/llviewertexteditor.cpp b/indra/newview/llviewertexteditor.cpp index aa5f5e0ae0..c2c3e7e320 100644 --- a/indra/newview/llviewertexteditor.cpp +++ b/indra/newview/llviewertexteditor.cpp @@ -616,7 +616,10 @@ BOOL LLViewerTextEditor::handleToolTip(S32 x, S32 y, std::string& msg, LLRect* s LLView *viewp = *child_iter; S32 local_x = x - viewp->getRect().mLeft; S32 local_y = y - viewp->getRect().mBottom; - if( viewp->handleToolTip(local_x, local_y, msg, sticky_rect_screen ) ) + if( viewp->pointInView(local_x, local_y) + && viewp->getVisible() + && viewp->getEnabled() + && viewp->handleToolTip(local_x, local_y, msg, sticky_rect_screen ) ) { return TRUE; } diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index edb339eab4..48b4a79afa 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -29,13 +29,13 @@ * $/LicenseInfo$ */ +#include "llviewerprecompiledheaders.h" + // system library includes #include #include #include -#include "llviewerprecompiledheaders.h" - #include "llpanellogin.h" #include "llviewerkeyboard.h" #include "llviewerwindow.h" @@ -183,7 +183,6 @@ #include "llviewernetwork.h" #if LL_WINDOWS -#include "llwindebug.h" #include // For Unicode conversion methods #endif @@ -1436,12 +1435,12 @@ LLViewerWindow::LLViewerWindow( !gNoRender, ignore_pixel_depth, gSavedSettings.getU32("RenderFSAASamples")); -#if LL_WINDOWS - if (!LLWinDebug::checkExceptionHandler()) + + if (!LLAppViewer::instance()->restoreErrorTrap()) { - LL_WARNS("Window") << " Someone took over my exception handler (post createWindow)!" << LL_ENDL; + LL_WARNS("Window") << " Someone took over my signal/exception handler (post createWindow)!" << LL_ENDL; } -#endif + if (NULL == mWindow) { @@ -3588,7 +3587,7 @@ LLViewerObject* LLViewerWindow::cursorIntersect(S32 mouse_x, S32 mouse_y, F32 de LLVector3 mouse_hud_end = mouse_point_hud + LLVector3(depth, 0, 0); // world coordinates of mouse - LLVector3 mouse_direction_global = mouseDirectionGlobal(x,y); + LLVector3 mouse_direction_global = mouseDirectionGlobal(x,y); LLVector3 mouse_point_global = LLViewerCamera::getInstance()->getOrigin(); LLVector3 mouse_world_start = mouse_point_global; LLVector3 mouse_world_end = mouse_point_global + mouse_direction_global * depth; @@ -4620,12 +4619,10 @@ void LLViewerWindow::restoreGL(const std::string& progress_message) setProgressString(progress_message); } llinfos << "...Restoring GL done" << llendl; -#if LL_WINDOWS - if(!LLWinDebug::checkExceptionHandler()) + if(!LLAppViewer::instance()->restoreErrorTrap()) { - llwarns << " Someone took over my exception handler (post restoreGL)!" << llendl; + llwarns << " Someone took over my signal/exception handler (post restoreGL)!" << llendl; } -#endif } } @@ -5232,7 +5229,7 @@ void LLPickInfo::fetchResults() LLVector3 intersection, normal, binormal; LLVector2 uv; - LLViewerObject* hit_object = gViewerWindow->cursorIntersect(-1, -1, 512.f, + LLViewerObject* hit_object = gViewerWindow->cursorIntersect(mMousePt.mX, mMousePt.mY, 512.f, NULL, -1, mPickTransparent, &face_hit, &intersection, &uv, &normal, &binormal); diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index aec26fa6a1..109b816182 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -272,6 +272,7 @@ LLUUID LLVOAvatar::sStepSounds[LL_MCODE_END] = LLUUID(SND_RUBBER_RUBBER) }; +// static S32 LLVOAvatar::sRenderName = RENDER_NAME_ALWAYS; BOOL LLVOAvatar::sRenderGroupTitles = TRUE; S32 LLVOAvatar::sNumVisibleChatBubbles = 0; @@ -284,9 +285,10 @@ BOOL LLVOAvatar::sVisibleInFirstPerson = FALSE; F32 LLVOAvatar::sLODFactor = 1.f; BOOL LLVOAvatar::sUseImpostors = FALSE; BOOL LLVOAvatar::sJointDebug = FALSE; - S32 LLVOAvatar::sCurJoint = 0; S32 LLVOAvatar::sCurVolume = 0; +F32 LLVOAvatar::sUnbakedTime = 0.f; +F32 LLVOAvatar::sGreyTime = 0.f; struct LLAvatarTexData { @@ -1070,8 +1072,10 @@ void LLVOAvatar::deleteLayerSetCaches() } // static -BOOL LLVOAvatar::areAllNearbyInstancesBaked() +BOOL LLVOAvatar::areAllNearbyInstancesBaked(S32& grey_avatars) { + BOOL res = TRUE; + grey_avatars = 0; for (std::vector::iterator iter = LLCharacter::sInstances.begin(); iter != LLCharacter::sInstances.end(); ++iter) { @@ -1080,18 +1084,22 @@ BOOL LLVOAvatar::areAllNearbyInstancesBaked() { continue; } - else - if( inst->getPixelArea() < MIN_PIXEL_AREA_FOR_COMPOSITE ) - { - return TRUE; // Assumes sInstances is sorted by pixel area. - } +// else +// if( inst->getPixelArea() < MIN_PIXEL_AREA_FOR_COMPOSITE ) +// { +// return res; // Assumes sInstances is sorted by pixel area. +// } else if( !inst->isFullyBaked() ) { - return FALSE; + res = FALSE; + if (inst->mHasGrey) + { + ++grey_avatars; + } } } - return TRUE; + return res; } // static @@ -1602,7 +1610,7 @@ BOOL LLVOAvatar::lineSegmentIntersect(const LLVector3& start, const LLVector3& e ) { - if (mIsSelf && !gAgent.needsRenderAvatar()) + if (mIsSelf && !gAgent.needsRenderAvatar() || !LLPipeline::sPickAvatar) { return FALSE; } @@ -4523,6 +4531,7 @@ void LLVOAvatar::updateTextures(LLAgent &agent) mMaxPixelArea = 0.f; mMinPixelArea = 99999999.f; + mHasGrey = FALSE; // debug for (U32 i = 0; i < getNumTEs(); i++) { LLViewerImage *imagep = getTEImage(i); @@ -4681,22 +4690,35 @@ void LLVOAvatar::updateTextures(LLAgent &agent) void LLVOAvatar::addLocalTextureStats( LLVOAvatar::ELocTexIndex idx, LLViewerImage* imagep, F32 texel_area_ratio, BOOL render_avatar, BOOL covered_by_baked ) { - if (!covered_by_baked && - render_avatar && // always true if mIsSelf - mLocalTexture[ idx ].notNull() && mLocalTexture[idx]->getID() != IMG_DEFAULT_AVATAR) - { - F32 desired_pixels; - if( mIsSelf ) + if (!covered_by_baked && render_avatar) // render_avatar is always true if mIsSelf + { + if (mLocalTexture[ idx ].notNull() && mLocalTexture[idx]->getID() != IMG_DEFAULT_AVATAR) { - desired_pixels = llmin(mPixelArea, (F32)LOCTEX_IMAGE_AREA_SELF ); - imagep->setBoostLevel(LLViewerImage::BOOST_AVATAR_SELF); + F32 desired_pixels; + if( mIsSelf ) + { + desired_pixels = llmin(mPixelArea, (F32)LOCTEX_IMAGE_AREA_SELF ); + imagep->setBoostLevel(LLViewerImage::BOOST_AVATAR_SELF); + } + else + { + desired_pixels = llmin(mPixelArea, (F32)LOCTEX_IMAGE_AREA_OTHER ); + imagep->setBoostLevel(LLViewerImage::BOOST_AVATAR); + } + imagep->addTextureStats( desired_pixels, texel_area_ratio ); + if (imagep->getDiscardLevel() < 0) + { + mHasGrey = TRUE; // for statistics gathering + } } else { - desired_pixels = llmin(mPixelArea, (F32)LOCTEX_IMAGE_AREA_OTHER ); - imagep->setBoostLevel(LLViewerImage::BOOST_AVATAR); + if (mLocalTexture[idx]->getID() == IMG_DEFAULT_AVATAR) + { + // texture asset is missing + mHasGrey = TRUE; // for statistics gathering + } } - imagep->addTextureStats( desired_pixels, texel_area_ratio ); } } @@ -9126,10 +9148,17 @@ void LLVOAvatar::cullAvatarsByPixelArea() } } - if( LLVOAvatar::areAllNearbyInstancesBaked() ) + S32 grey_avatars = 0; + if( LLVOAvatar::areAllNearbyInstancesBaked(grey_avatars) ) { LLVOAvatar::deleteCachedImages(); } + else + { + sUnbakedTime += gFrameTimeSeconds; + if (grey_avatars > 0) + sGreyTime += gFrameTimeSeconds; + } } const LLUUID& LLVOAvatar::grabLocalTexture(ETextureIndex index) diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h index 74fdb72c84..9c2ffc2d77 100644 --- a/indra/newview/llvoavatar.h +++ b/indra/newview/llvoavatar.h @@ -913,6 +913,9 @@ public: static BOOL sJointDebug; static ETextureIndex sBakedTextureIndices[BAKED_TEXTURE_COUNT]; + static F32 sUnbakedTime; // Total seconds with >=1 unbaked avatars + static F32 sGreyTime; // Total seconds with >=1 grey avatars + //-------------------------------------------------------------------- // Texture Layer Sets and Global Colors //-------------------------------------------------------------------- @@ -977,6 +980,7 @@ protected: F32 mLastFadeDistance; F32 mMinPixelArea; // debug F32 mMaxPixelArea; // debug + BOOL mHasGrey; // debug //-------------------------------------------------------------------- // Global Colors @@ -1012,7 +1016,7 @@ protected: BOOL isFullyBaked(); void deleteLayerSetCaches(); - static BOOL areAllNearbyInstancesBaked(); + static BOOL areAllNearbyInstancesBaked(S32& grey_avatars); static void onBakedTextureMasksLoaded(BOOL success, LLViewerImage *src_vi, LLImageRaw* src, LLImageRaw* aux_src, S32 discard_level, BOOL final, void* userdata); diff --git a/indra/newview/llvosurfacepatch.cpp b/indra/newview/llvosurfacepatch.cpp index e912a19f81..13741f0b79 100644 --- a/indra/newview/llvosurfacepatch.cpp +++ b/indra/newview/llvosurfacepatch.cpp @@ -945,45 +945,55 @@ BOOL LLVOSurfacePatch::lineSegmentIntersect(const LLVector3& start, const LLVect //step one meter at a time until intersection point found + const LLVector3* ext = mDrawable->getSpatialExtents(); + F32 rad = (delta*tdelta).magVecSquared(); + F32 t = 0.f; while ( t <= 1.f) { LLVector3 sample = origin + delta*t; - F32 height = mRegionp->getLandHeightRegion(sample); - if (height > sample.mV[2]) - { //ray went below ground, positive intersection - //quick and dirty binary search to get impact point - tdelta = -tdelta*0.5f; - F32 err_dist = 0.001f; - F32 dist = fabsf(sample.mV[2] - height); - - while (dist > err_dist && tdelta*tdelta > 0.0f) - { - t += tdelta; - sample = origin+delta*t; - height = mRegionp->getLandHeightRegion(sample); - if ((tdelta < 0 && height < sample.mV[2]) || - (height > sample.mV[2] && tdelta > 0)) - { //jumped over intersection point, go back - tdelta = -tdelta; + if (AABBSphereIntersectR2(ext[0], ext[1], sample+mRegionp->getOriginAgent(), rad)) + { + F32 height = mRegionp->getLandHeightRegion(sample); + if (height > sample.mV[2]) + { //ray went below ground, positive intersection + //quick and dirty binary search to get impact point + tdelta = -tdelta*0.5f; + F32 err_dist = 0.001f; + F32 dist = fabsf(sample.mV[2] - height); + + while (dist > err_dist && tdelta*tdelta > 0.0f) + { + t += tdelta; + sample = origin+delta*t; + height = mRegionp->getLandHeightRegion(sample); + if ((tdelta < 0 && height < sample.mV[2]) || + (height > sample.mV[2] && tdelta > 0)) + { //jumped over intersection point, go back + tdelta = -tdelta; + } + tdelta *= 0.5f; + dist = fabsf(sample.mV[2] - height); } - tdelta *= 0.5f; - dist = fabsf(sample.mV[2] - height); - } - if (intersection) - { - sample.mV[2] = mRegionp->getLandHeightRegion(sample); - *intersection = sample + mRegionp->getOriginAgent(); - } + if (intersection) + { + F32 height = mRegionp->getLandHeightRegion(sample); + if (fabsf(sample.mV[2]-height) < delta.length()*tdelta) + { + sample.mV[2] = mRegionp->getLandHeightRegion(sample); + } + *intersection = sample + mRegionp->getOriginAgent(); + } - if (normal) - { - *normal = mRegionp->getLand().resolveNormalGlobal(mRegionp->getPosGlobalFromRegion(sample)); - } + if (normal) + { + *normal = mRegionp->getLand().resolveNormalGlobal(mRegionp->getPosGlobalFromRegion(sample)); + } - return TRUE; + return TRUE; + } } t += tdelta; diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 50cf336d07..6766898644 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -1998,7 +1998,7 @@ BOOL LLVOVolume::lineSegmentIntersect(const LLVector3& start, const LLVector3& e face_hit = volume->lineSegmentIntersect(v_start, v_end, i, &p, &tc, &n, &bn); - if (face_hit >= 0) + if (face_hit >= 0 && mDrawable->getNumFaces() > face_hit) { LLFace* face = mDrawable->getFace(face_hit); if (pick_transparent || !face->getTexture() || face->getTexture()->getMask(face->surfaceToTexture(tc, p, n))) diff --git a/indra/newview/llwatchdog.cpp b/indra/newview/llwatchdog.cpp index 27a0155b14..c611aa0b91 100644 --- a/indra/newview/llwatchdog.cpp +++ b/indra/newview/llwatchdog.cpp @@ -35,6 +35,15 @@ const U32 WATCHDOG_SLEEP_TIME_USEC = 1000000; +void default_killer_callback() +{ +#ifdef LL_WINDOWS + RaiseException(0,0,0,0); +#else + raise(SIGQUIT); +#endif +} + // This class runs the watchdog timing thread. class LLWatchdogTimerThread : public LLThread { @@ -52,7 +61,7 @@ public: void stop() { mStopping = true; - ms_sleep(1); + mSleepMsecs = 1; } /* virtual */ void run() @@ -146,7 +155,8 @@ void LLWatchdogTimeout::ping(const std::string& state) LLWatchdog::LLWatchdog() : mSuspectsAccessMutex(NULL), mTimer(NULL), - mLastClockCount(0) + mLastClockCount(0), + mKillerCallback(&default_killer_callback) { } @@ -168,8 +178,9 @@ void LLWatchdog::remove(LLWatchdogEntry* e) unlockThread(); } -void LLWatchdog::init() +void LLWatchdog::init(killer_event_callback func) { + mKillerCallback = func; if(!mSuspectsAccessMutex && !mTimer) { mSuspectsAccessMutex = new LLMutex(NULL); @@ -238,11 +249,7 @@ void LLWatchdog::run() } llinfos << "Watchdog detected error:" << llendl; -#ifdef LL_WINDOWS - RaiseException(0,0,0,0); -#else - raise(SIGQUIT); -#endif + mKillerCallback(); } } diff --git a/indra/newview/llwatchdog.h b/indra/newview/llwatchdog.h index 0bcf11c3a3..ba2eac47ba 100644 --- a/indra/newview/llwatchdog.h +++ b/indra/newview/llwatchdog.h @@ -32,6 +32,8 @@ #ifndef LL_LLTHREADWATCHDOG_H #define LL_LLTHREADWATCHDOG_H +#include + #ifndef LL_TIMER_H #include "lltimer.h" #endif @@ -85,7 +87,9 @@ public: void add(LLWatchdogEntry* e); void remove(LLWatchdogEntry* e); - void init(); + typedef boost::function killer_event_callback; + + void init(killer_event_callback func = NULL); void run(); void cleanup(); @@ -98,6 +102,8 @@ private: LLMutex* mSuspectsAccessMutex; LLWatchdogTimerThread* mTimer; U64 mLastClockCount; + + killer_event_callback mKillerCallback; }; #endif // LL_LLTHREADWATCHDOG_H diff --git a/indra/newview/llwindebug.cpp b/indra/newview/llwindebug.cpp index a1a3b1cf1a..08e30d81df 100644 --- a/indra/newview/llwindebug.cpp +++ b/indra/newview/llwindebug.cpp @@ -42,6 +42,7 @@ #pragma warning(disable: 4200) //nonstandard extension used : zero-sized array in struct/union #pragma warning(disable: 4100) //unreferenced formal parameter + /* LLSD Block for Windows Dump Information @@ -429,7 +430,7 @@ LLSD WINAPI Get_Exception_Info(PEXCEPTION_POINTERS pException) FILETIME Last_Write_Time; FILETIME Local_File_Time; SYSTEMTIME T; - + Str = new WCHAR[DUMP_SIZE_MAX]; Str_Len = 0; if (!Str) @@ -439,6 +440,7 @@ LLSD WINAPI Get_Exception_Info(PEXCEPTION_POINTERS pException) GetModuleFileName(NULL, Str, MAX_PATH); info["Process"] = ll_convert_wide_to_string(Str); + info["ThreadID"] = (S32)GetCurrentThreadId(); // If exception occurred. if (pException) @@ -552,6 +554,58 @@ void LLMemoryReserve::release() static LLMemoryReserve gEmergencyMemoryReserve; +#ifndef _M_IX86 + #error "The following code only works for x86!" +#endif +LPTOP_LEVEL_EXCEPTION_FILTER WINAPI MyDummySetUnhandledExceptionFilter( + LPTOP_LEVEL_EXCEPTION_FILTER lpTopLevelExceptionFilter) +{ + if(lpTopLevelExceptionFilter == gFilterFunc) + return gFilterFunc; + + llinfos << "Someone tried to set the exception filter. Listing call stack modules" << llendl; + LLSD cs_info; + GetCallStackData(NULL, cs_info); + + if(cs_info.has("CallStack") && cs_info["CallStack"].isArray()) + { + LLSD cs = cs_info["CallStack"]; + for(LLSD::array_iterator i = cs.beginArray(); + i != cs.endArray(); + ++i) + { + llinfos << "Module: " << (*i)["ModuleName"] << llendl; + } + } + + return gFilterFunc; +} + +BOOL PreventSetUnhandledExceptionFilter() +{ + HMODULE hKernel32 = LoadLibrary(_T("kernel32.dll")); + if (hKernel32 == NULL) + return FALSE; + + void *pOrgEntry = GetProcAddress(hKernel32, "SetUnhandledExceptionFilter"); + if(pOrgEntry == NULL) + return FALSE; + + unsigned char newJump[ 100 ]; + DWORD dwOrgEntryAddr = (DWORD)pOrgEntry; + dwOrgEntryAddr += 5; // add 5 for 5 op-codes for jmp far + void *pNewFunc = &MyDummySetUnhandledExceptionFilter; + DWORD dwNewEntryAddr = (DWORD) pNewFunc; + DWORD dwRelativeAddr = dwNewEntryAddr - dwOrgEntryAddr; + + newJump[ 0 ] = 0xE9; // JMP absolute + memcpy(&newJump[ 1 ], &dwRelativeAddr, sizeof(pNewFunc)); + SIZE_T bytesWritten; + BOOL bRet = WriteProcessMemory(GetCurrentProcess(), + pOrgEntry, newJump, sizeof(pNewFunc) + 1, &bytesWritten); + return bRet; +} + // static void LLWinDebug::initExceptionHandler(LPTOP_LEVEL_EXCEPTION_FILTER filter_func) { @@ -602,6 +656,9 @@ void LLWinDebug::initExceptionHandler(LPTOP_LEVEL_EXCEPTION_FILTER filter_func) LPTOP_LEVEL_EXCEPTION_FILTER prev_filter; prev_filter = SetUnhandledExceptionFilter(filter_func); + // *REMOVE:Mani + //PreventSetUnhandledExceptionFilter(); + if(prev_filter != gFilterFunc) { LL_WARNS("AppInit") @@ -737,3 +794,10 @@ void LLWinDebug::generateCrashStacks(struct _EXCEPTION_POINTERS *exception_infop LLSDSerialize::toPrettyXML(info, out_file); out_file.close(); } + +void LLWinDebug::clearCrashStacks() +{ + LLSD info; + std::string dump_path = gDirUtilp->getExpandedFilename(LL_PATH_LOGS, "SecondLifeException.log"); + LLFile::remove(dump_path); +} diff --git a/indra/newview/llwindebug.h b/indra/newview/llwindebug.h index 6875b943ae..531b58033b 100644 --- a/indra/newview/llwindebug.h +++ b/indra/newview/llwindebug.h @@ -39,7 +39,6 @@ class LLWinDebug { public: - /** * @brief initialize the llwindebug exception filter callback * @@ -66,6 +65,8 @@ public: static bool checkExceptionHandler(); static void generateCrashStacks(struct _EXCEPTION_POINTERS *pExceptionInfo = NULL); + static void clearCrashStacks(); // Delete the crash stack file(s). + static void writeDumpToFile(MINIDUMP_TYPE type, MINIDUMP_EXCEPTION_INFORMATION *ExInfop, const std::string& filename); private: }; diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index 817331b990..376c712179 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -220,6 +220,7 @@ void display_update_camera(); S32 LLPipeline::sCompiles = 0; +BOOL LLPipeline::sPickAvatar = TRUE; BOOL LLPipeline::sDynamicLOD = TRUE; BOOL LLPipeline::sShowHUDAttachments = TRUE; BOOL LLPipeline::sRenderPhysicalBeacons = TRUE; @@ -2342,7 +2343,7 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate) } } - + LLAppViewer::instance()->pingMainloopTimeout("Pipeline:ForceVBO"); //by bao //fake vertex buffer updating @@ -2389,12 +2390,16 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate) U32 cur_type = 0; + LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDrawPools"); + if (gPipeline.hasRenderDebugMask(LLPipeline::RENDER_DEBUG_PICKING)) { + LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderForSelect"); gObjectList.renderObjectsForSelect(camera, gViewerWindow->getVirtualWindowRect()); } else if (gSavedSettings.getBOOL("RenderDeferred")) { + LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDeferred"); renderGeomDeferred(); } else @@ -2482,6 +2487,8 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate) stop_glerror(); } } + + LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDrawPoolsEnd"); LLVertexBuffer::unbind(); LLGLState::checkStates(); @@ -2505,6 +2512,8 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate) LLGLState::checkTextureChannels(); LLGLState::checkClientArrays(); + LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderHighlights"); + if (!sReflectionRender) { renderHighlights(); @@ -2514,6 +2523,8 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate) // have touch-handlers. mHighlightFaces.clear(); + LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderDebug"); + renderDebug(); LLVertexBuffer::unbind(); @@ -2526,6 +2537,8 @@ void LLPipeline::renderGeom(LLCamera& camera, BOOL forceVBOUpdate) gObjectList.resetObjectBeacons(); } + LLAppViewer::instance()->pingMainloopTimeout("Pipeline:RenderGeomEnd"); + //HACK: preserve/restore matrices around HUD render if (gPipeline.hasRenderType(LLPipeline::RENDER_TYPE_HUD)) { @@ -4022,6 +4035,8 @@ LLViewerObject* LLPipeline::lineSegmentIntersectInWorld(const LLVector3& start, LLVector3 position; + sPickAvatar = LLToolMgr::getInstance()->inBuildMode() ? FALSE : TRUE; + for (LLWorld::region_list_t::iterator iter = LLWorld::getInstance()->getRegionList().begin(); iter != LLWorld::getInstance()->getRegionList().end(); ++iter) { @@ -4048,6 +4063,31 @@ LLViewerObject* LLPipeline::lineSegmentIntersectInWorld(const LLVector3& start, } } } + + if (!sPickAvatar) + { + if (!drawable || !drawable->getVObj()->isAttachment()) + { //check against avatars + sPickAvatar = TRUE; + for (LLWorld::region_list_t::iterator iter = LLWorld::getInstance()->getRegionList().begin(); + iter != LLWorld::getInstance()->getRegionList().end(); ++iter) + { + LLViewerRegion* region = *iter; + + LLSpatialPartition* part = region->getSpatialPartition(LLViewerRegion::PARTITION_BRIDGE); + if (part && hasRenderType(part->mDrawableType)) + { + LLDrawable* hit = part->lineSegmentIntersect(start, local_end, pick_transparent, face_hit, &position, tex_coord, normal, bi_normal); + if (hit) + { + drawable = hit; + local_end = position; + } + } + } + } + } + //check all avatar nametags (silly, isn't it?) for (std::vector< LLCharacter* >::iterator iter = LLCharacter::sInstances.begin(); diff --git a/indra/newview/pipeline.h b/indra/newview/pipeline.h index bacfed0aed..8e64b64cb7 100644 --- a/indra/newview/pipeline.h +++ b/indra/newview/pipeline.h @@ -319,7 +319,6 @@ public: // RENDER_DEBUG_FEATURE_HW_LIGHTING = 0x0010, RENDER_DEBUG_FEATURE_FLEXIBLE = 0x0010, RENDER_DEBUG_FEATURE_FOG = 0x0020, - RENDER_DEBUG_FEATURE_PALETTE = 0x0040, RENDER_DEBUG_FEATURE_FR_INFO = 0x0080, RENDER_DEBUG_FEATURE_FOOT_SHADOWS = 0x0100, }; @@ -384,6 +383,7 @@ public: static BOOL sSkipUpdate; //skip lod updates static BOOL sWaterReflections; static BOOL sDynamicLOD; + static BOOL sPickAvatar; static BOOL sReflectionRender; static BOOL sImpostorRender; static BOOL sUnderWaterRender; diff --git a/indra/newview/skins/default/xui/da/floater_about.xml b/indra/newview/skins/default/xui/da/floater_about.xml new file mode 100644 index 0000000000..48ca5401ed --- /dev/null +++ b/indra/newview/skins/default/xui/da/floater_about.xml @@ -0,0 +1,35 @@ + + + + Second Life er gjort muligt for dig af Philip, Tessa, Andrew, Cory, James, Ben, Char, Charlie, Colin, Dan, Daniel, Doug, Eric, Hamlet, Haney, Eve, Hunter, Ian, Jeff, Jennifer, Jim, John, Lee, Mark, Peter, Phoenix, Richard, Robin, Xenon, Steve, Tanya, Eddie, Avi, Frank, Bruce, Aaron, Alice, Bob, Debra, Eileen, Helen, Janet, Louie, Leviathania, Stefan, Ray, Kevin, Tom, Mikeb, MikeT, Burgess, Elena, Tracy, Bill, Todd, Ryan, Zach, Sarah, Nova, Tim, Stephanie, Michael, Evan, Nicolas, Catherine, Rachelle, Dave, Holly, Bub, Kelly, Magellan, Ramzi, Don, Sabin, Jill, Rheya, Jeska, Torley, Kona, Callum, Charity, Ventrella, Jack, Vektor, Iris, Chris, Nicole, Mick, Reuben, Blue, Babbage, Yedwab, Deana, Lauren, Brent, Pathfinder, Chadrick, Altruima, Jesse, Teeny, Monroe, Icculus, David, Tess, Lizzie, Patsy, Isaac, Lawrence, Cyn, Bo, Gia, Annette, Marius, Tbone, Jonathan, Karen, Ginsu, Satoko, Yuko, Makiko, Thomas, Harry, Seth, Alexei, Brian, Guy, Runitai, Ethan, Data, Cornelius, Kenny, Swiss, Zero, Natria, Wendy, Stephen, Teeple, Thumper, Lucy, Dee, Mia, Liana, Warren, Branka, Aura, beez, Milo, Hermia, Red, Thrax, Joe, Sally, Magenta, Mogura, Paul, Jose, Rejean, Henrik, Lexie, Amber, Logan, Xan, Nora, Morpheus, Donovan, Leyla, MichaelFrancis, Beast, Cube, Bucky, Joshua, Stryfe, Harmony, Teresa, Claudia, Walker, Glenn, Fritz, Fordak, June, Cleopetra, Jean, Ivy, Betsy, Roosevelt, Spike, Ken, Which, Tofu, Chiyo, Rob, Zee, dustin, George, Del, Matthew, Cat, Jacqui, Lightfoot, Adrian, Viola, Alfred, Noel, Irfan, Sunil, Yool, Rika, Jane, Xtreme, Frontier, a2, Neo, Siobhan, Yoz, Justin, Elle, Qarl, Benjamin, Isabel, Gulliver, Everett, Christopher, Izzy, Stephany, Garry, Sejong, Sean, Tobin, Iridium, Meta, Anthony, Jeremy, JP, Jake, Maurice, Madhavi, Leopard, Kyle, Joon, Kari, Bert, Belinda, Jon, Kristi, Bridie, Pramod, KJ, Socrates, Maria, Ivan, Aric, Yamasaki, Adreanne, Jay, MitchK, Ceren, Coco, Durl, Jenny, Periapse, Kartic, Storrs, Lotte, Sandy, Rohn, Colossus, Zen, BigPapi, Brad, Pastrami, Kurz, Mani, Neuro, Jaime, MJ, Rowan, Sgt, Elvis, Gecko, Samuel, Sardonyx, Leo, Bryan, Niko, Soft, Poppy, Rachel, Aki, Angelo, Banzai, Alexa, Sue, CeeLo, Bender, CG, Gillian, Pelle, Nick, Echo, Zara, Christine, Shamiran, Emma, Blake, Keiko, Plexus, Joppa, Sidewinder, Erica, Ashlei, Twilight, Kristen, Brett, Q, Enus, Simon, Bevis, Kraft, Kip, Chandler, Ron, LauraP, Ram, KyleJM, Scouse, Prospero, Melissa, Marty, Nat, Hamilton, Kend, Lordan, Jimmy, Kosmo, Seraph, Green, Ekim, Wiggo, JT, Rome, Doris, Miz, Benoc, Whump, Trinity, Patch, Kate, TJ, Bao, Joohwan, Christy, Sofia, Matias, Cogsworth, Johan, Oreh, Cheah, Angela, Brandy, Mango, Lan, Aleks, Gloria, Heidy, Mitchell, Space, Colton, Bambers, Einstein, Maggie, Malbers, Rose, Winnie, Stella, Milton, Rothman, Niall, Marin, Allison, Katie, Dawn, Katt, Dusty, Kalpana, Judy, Andrea, Ambroff, Infinity, Gail, Rico, Raymond, Yi, William, Christa, M, Teagan, Scout, Molly, Dante, Corr, Dynamike, Usi, Kaylee, Vidtuts, Lil, Danica, Sascha, Kelv, Jacob, Nya, Rodney, Brandon, Elsie, Blondin, Grant, Katrin, Nyx, Gabriel, Locklainn, Claire, Devin, Minerva, Monty, Austin, Bradford, Si, Keira, H, Caitlin, Dita, Makai, Jenn, Ann, Meredith, Clare, Joy, Praveen, Cody, Edmund, Ruthe, Sirena, Gayathri, Spider, FJ, Davidoff, Tian, Jennie, Louise, Oskar, Landon, Noelle, Jarv, Ingrid, Al, Sommer, Doc, Aria, Huin, Gray, Lili, Vir, DJ and many others. + +Tak til følgende beboerne for at bidrage til at sikre, at dette er den bedste version til dato: Aminom Marvin, ava ganache, Balthazar Fouroux, CrystalShard Foo, Davec Horsforth, Drew Dwi, Ellla McMahon, Gellan Glenelg, Harleen Gretzky, istephanija munro, Iustinian Tomsen, JC Glimmer, Joeseph Albanese, kelly young, Latif Khalifa, Lex Neva, McCabe Maxsted, Michi Lumin, moni duettmann, Moon Metty, motor loon, Opensource Obscure, Sky Hye, Soap Clawtooth, velveeta biedermann, zeebster colasanti + + 3Dconnexion SDK Copyright (C) 1992-2007 3Dconnexion + APR Copyright (C) 2000-2004 The Apache Software Foundation + cURL Copyright (C) 1996-2002, Daniel Stenberg, (daniel@haxx.se) + DBus/dbus-glib Copyright (C) 2002, 2003 CodeFactory AB / Copyright (C) 2003, 2004 Red Hat, Inc. + expat Copyright (C) 1998, 1999, 2000 Thai Open Source Software Center Ltd. + FreeType Copyright (C) 1996-2002, The FreeType Project (www.freetype.org). + GL Copyright (C) 1999-2004 Brian Paul. + Havok.com(TM) Copyright (C) 1999-2001, Telekinesys Research Limited. + jpeg2000 Copyright (C) 2001, David Taubman, The University of New South Wales (UNSW) + jpeglib Copyright (C) 1991-1998, Thomas G. Lane. + ogg/vorbis Copyright (C) 2001, Xiphophorus + OpenSSL Copyright (C) 1998-2002 The OpenSSL Project. + SDL Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga + SSLeay Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) + xmlrpc-epi Copyright (C) 2000 Epinions, Inc. + zlib Copyright (C) 1995-2002 Jean-loup Gailly and Mark Adler. + +Alle rettigheder forbeholdes. Se licenses.txt for detaljer. + +Voice chat Audio coding: Polycom(R) Siren14(TM) (ITU-T Rec. G.722.1 Annex C) + + +We can only see a short distance ahead, but we can see plenty there that needs to be done. --Alan Turing + + + Du er ved [POSITION] + + diff --git a/indra/newview/skins/default/xui/da/floater_about_land.xml b/indra/newview/skins/default/xui/da/floater_about_land.xml new file mode 100644 index 0000000000..7163b149e8 --- /dev/null +++ b/indra/newview/skins/default/xui/da/floater_about_land.xml @@ -0,0 +1,431 @@ + + + + + + Navn: + + + Beskrivelse: + + + Ejer: + + + Leyla Linden + +